Frequency based transit trip characterizations

ABSTRACT

Some embodiments provide a map application that identifies a transit route between a starting location and a destination. The transit route, in some embodiments, includes a set of transit legs that each is serviced by transit vehicles of a transit line. The map application of some embodiments, after identifying the transit route, categorizes each transit line of the transit route as one of a high frequency transit line and a low frequency transit line. The map application displays the departure schedules of high frequency transit lines in a first manner, while the map application displays the departure schedules of low frequency transit lines in a second different manner.

CLAIM OF BENEFIT TO PRIOR APPLICATIONS

This application claims the benefit of U.S. Provisional PatentApplication 62/172,206, filed Jun. 7, 2015; U.S. Provisional PatentApplication 62/172,209, filed Jun. 7, 2015; U.S. Provisional PatentApplication 62/172,214, filed Jun. 7, 2015; and U.S. Provisional PatentApplication 62/172,216, filed Jun. 7, 2015. U.S. Provisional PatentApplications 62/172,206, 62/172,209, 62/172,214, and 62/172,216 areincorporated herein by reference.

BRIEF SUMMARY

Some embodiments of the invention provide a map application thatprovides a comprehensive and efficient transit navigation modality forplanning a transit trip by browsing and selecting a transit route andnavigating the selected transit route. The map application of someembodiments operates in a map-browsing mode to allow a user to browse amap of a locality and to perform searches for map locations based onaddresses, names (e.g., people, businesses, etc.) or other searchparameters. The map application of some such embodiments also has anavigation mode that includes a driving navigation mode to providedriving navigation directions, a walking navigation mode to providewalking navigation directions, and a transit navigation mode to providetransit navigation directions.

The map application of some embodiments, upon receiving a request todisplay a route in transit mode, identifies one or more transit routesbetween two locations and displays the best possible transit route amongthe identified routes to the user. Specifically, to identify the transitroutes, the application of some embodiments examines different transitlegs that one or more transit vehicles of one or more transit systemstravel from locations near a specified starting location (e.g., thecurrent location of the device) to locations near a specifieddestination. In some embodiments, each transit leg of a transit routeincludes a section of the transit route that is travelled by a transitvehicle of a transit line. A transit leg may also include a walkingdistance that is more than a threshold distance.

In examining the transit legs, the application of some embodiments takesinto account a set of transit preferences that are customized (i.e., setor adjusted) by the user. For instance, in some embodiments, a user mayadjust the date and time of the departure (from, e.g., the currentlocation of the user) to a particular date and time instead of thecurrent time. Conversely, the user may prefer a particular type oftransit vehicle (i.e., a transit vehicle of a particular transit system)over the other types. For example, the user might rather ride a subwaytrain over a bus for a particular transit leg of a transit route, or useonly ground transportation for an entire transit route (e.g., a transitroute without any ferry trips).

Based on the examination of the transit legs, the map applicationidentifies one or more transit routes that use one or more transitvehicles of one or more transit systems in some embodiments. Theidentified transit routes may also include one or more pedestrian routesthat are between the different transit legs, between the startinglocation and the first transit leg, and between the last transit leg andthe destination location. After identifying the transit routes, the mapapplication selects one of the identified transit routes based on a setof criteria (e.g., fastest route, shortest route, route with leastamount of walking, route requiring least amount of transit vehiclechanges, route requiring least amount of transit system changes, etc.).In some embodiments, the set of selection criteria relies on two or moreselection parameters. Also, in some embodiments, the set of selectioncriteria is different in different transit markets and/or in differenttime periods in the same transit market.

The map application of some embodiments displays the best identifiedroute in its entirety over a portion of a map presentation of ageographical area. The application of some such embodiments displays theidentified route in multiple sections (transit legs) each of which istraveled by a transit vehicle of a particular transit line. The mapapplication uses different graphical representations for differentportions of a displayed transit route that are travelled by differenttypes of transit vehicles or require walking.

In some embodiments, the different types of transit vehicles that arepresented by different graphical representations include buses, subwaytrains, rail trains (e.g., light rail trains and heavy rail trains), andferries. Each of these four categories may include multiple differentsubcategories in some embodiments and additional transit categories(e.g., tramways, trolleys, etc.) may be present in some embodiments.When the selected transit route includes multiple transit vehicles ofthe same type (same transit system), each transit vehicle of the sametransit system is distinguished from the other transit vehicles by adifferent line of the transit vehicle.

Some embodiments categorize different transit lines of a transit routeinto two categories of high frequency transit lines and low frequencytransit lines. In some such embodiments a first transit line (e.g., afirst bus line) can be categorized as a low frequency transit line at aparticular transit station, while a second different transit line (e.g.,a second bus line) can be categorized as a high frequency transit lineat the particular transit station. Conversely, in some embodiments, atransit line can be categorized as a high frequency transit line at aparticular transit station during a first time period (e.g., on evendays of the week, in the mornings, between two particular hours, etc.),while the same transit line can be categorized as a low frequencytransit line at the same particular station but during a seconddifferent time period (e.g., on odd days of the week, in the evenings,between two particular hours, etc.).

The map application of some embodiments treats the high frequencytransit lines differently than the low frequency transit lines. Forexample, the application presents the departure times of high frequencytransit vehicles in a first manner while it presents the departure timesof low frequency transit vehicles in a second different manner indifferent display areas of the UI of the application. Additionally, theapplication of some embodiments classifies high frequency transit linesinto different classes and presents the frequency of departure for eachclass differently. Characterizing the transit lines as high frequencytransit lines and low frequency transit lines and computing thefrequency of departures of a particular transit line are done by amapping service that runs on one or more dedicated servers in someembodiments.

In order to determine the frequency of departures of a transit line froma transit station during a particular time period, the mapping serviceof some embodiments first determines whether the transit vehicles of theline depart from the transit station on average at least once during acertain time period (e.g., every 30 minutes for at least 2 hours). Thiscertain time period can be different in different areas or for differenttransit lines of the same or different transit systems. When the mappingservice of some such embodiments determines that the vehicles of thetransit line depart at least once during the certain time period, theservice categorizes the transit vehicles of the line as high frequencytransit vehicles. The mapping service then computes the frequency ofdepartures for high frequency transit lines.

In order to compute the frequency, the mapping service of someembodiments first identifies the time intervals between each pair ofdepartures of the transit vehicles of the line that head the samedirection from the same transit station during a particular time period.The service then applies a series of mathematical functions and formulasto the identified numbers (i.e., the sequence of the gaps between thedeparture times) in order to calculate the frequency of departures forthe line. In some embodiments the calculated departure frequency can bea value (number) that represents the exact frequency of departures(e.g., every 5 minutes), a number that represents an approximation offrequency of departures (e.g., about every 5 minutes), or a range ofnumbers (e.g., every 5-8 minutes). Some embodiments first determinewhether an exact frequency can be used, then determine (if no exactfrequency is found) whether one of a set of frequency ranges can beused, and only attempt to find an approximate frequency value if thefirst two options are unsuccessful.

For a high frequency transit line, the map application of someembodiments displays the departure time of the line in a frequencyformat. That is, the application displays the frequency of departures ofthe transit vehicles of the line (e.g., every 5 minutes, 5-10 minutes,etc.) from the transit station. For a low frequency transit line,however, the map application of some such embodiments displays thedeparture time in an absolute time format. That is the map applicationdisplays the time at which the transit vehicles of the line leave thestation (e.g., at 2:30 pm, at 3:30 pm). In some embodiments, theapplication displays only one frequency of departures for a highfrequency line (e.g., under the trip heading in a placecard), while itdisplays multiple departure times for the next transit vehicles of a lowfrequency line (e.g. the next three departure times of a train lineunder the trip heading of the line). Some embodiments also provide anoverall transit frequency for a selected transit route. That is, somesuch embodiments not only provide a transit frequency for each transitleg of the route that is services by a high frequency transit line, butalso provide a transit frequency for the sum of the transit legs of theroute.

Additionally, the map application of some embodiments can intelligentlyguide the user to plan for a transit trip based on the user's location.The map application of some such embodiments first identifies thelocation of the device on which the application runs. The applicationthen evaluates the distance between the device and the first transitstation at which the user boards the first transit vehicle. When theapplication realizes that the user is far away from the transit station(e.g., farther than a threshold distance), the application displays thetime by which the user should start the transit trip (i.e., the usershould leave the current location towards the first transit station). Onthe other hand, when the user is at or near the transit station (e.g.,closer than the threshold distance), the application displays the timeat which the first transit vehicle of the line leaves the transitstation.

The preceding Summary is intended to serve as a brief introduction tosome embodiments of the invention. It is not meant to be an introductionor overview of all-inventive subject matter disclosed in this document.The Detailed Description that follows and the Drawings that are referredto in the Detailed Description will further describe the embodimentsdescribed in the Summary as well as other embodiments. Accordingly, tounderstand all the embodiments described by this document, a full reviewof the Summary, Detailed Description and the Drawings is needed.Moreover, the claimed subject matters are not to be limited by theillustrative details in the Summary, Detailed Description and theDrawings, but rather are to be defined by the appended claims, becausethe claimed subject matters can be embodied in other specific formswithout departing from the spirit of the subject matters.

BRIEF DESCRIPTION OF THE DRAWINGS

The novel features of the invention are set forth in the appendedclaims. However, for purposes of explanation, several embodiments of theinvention are set forth in the following figures.

FIG. 1 illustrates how the transit navigation mode of a map applicationcan be selected.

FIG. 2 conceptually illustrates a process that some embodiments performto provide departure schedule of a transit line.

FIG. 3 illustrates the UI of the map application of some embodimentsthat displays the departure schedule of a subway train from a subwaystation in terms of three different examples.

FIG. 4 illustrates the UI of the map application of some embodimentsthat displays the departure schedule of a train (e.g., a light railtrain) from a train station in terms of two different examples.

FIG. 5 illustrates how a user can access and view a transit stationplacecard that provides transit schedules related to the transitstation.

FIG. 6 illustrates an example of a transit hub placecard that providestransit schedules for different types of transit vehicles and transitlines departing from the transit hub.

FIG. 7 conceptually illustrates a process that some embodiments performto determine how to express (present) the departure schedule of a highfrequency transit line.

FIG. 8 provides an example for calculating a range of departures as thedeparture schedule of a transit line at a particular station.

FIG. 9 conceptually illustrates a frequency generator module that someembodiments use for determining in which format the frequency ofdepartures should be displayed for a particular transit line leaving aparticular transit station at a particular time of day.

FIG. 10 conceptually illustrates a process that some embodiments performto calculate the overall transit frequency for a selected transit route.

FIG. 11 provides an example for calculating a sequence of departures(i.e., a window group) that includes the departure times from thecurrent position of the device.

FIG. 12 illustrates an example of an architecture of a mobile computingdevice of some embodiments.

FIG. 13 conceptually illustrates another example of an electronic systemwith which some embodiments of the invention are implemented.

FIG. 14 illustrates one possible embodiment of an operating environmentfor a map service (also referred to as a mapping service) and clientdevices.

DETAILED DESCRIPTION

In the following detailed description of the invention, numerousdetails, examples, and embodiments of the invention are set forth anddescribed. However, it will be clear and apparent to one skilled in theart that the invention is not limited to the embodiments set forth andthat the invention may be practiced without some of the specific detailsand examples discussed.

Some embodiments of the invention provide a map application thatprovides a comprehensive and efficient transit navigation modality forplanning a transit trip by browsing and selecting a transit route andnavigating the selected transit route. The map application of someembodiments operates in a map-browsing mode to allow a user to browse amap of a locality and to perform searches for map locations based onaddresses, names (e.g., people, businesses, etc.) or other searchparameters. The map application of some such embodiments also has anavigation mode that includes a driving navigation mode to providedriving navigation directions, a walking navigation mode to providewalking navigation directions, and a transit navigation mode to providetransit navigation directions.

The map application of some embodiments, upon receiving a request todisplay a route in transit mode, identifies one or more transit routesbetween two locations and displays the best possible transit route amongthe identified routes to the user. Specifically, to identify the transitroutes, the application of some embodiments examines different transitlegs that one or more transit vehicles of one or more transit systemstravel from locations near a specified starting location (e.g., thecurrent location of the device) to locations near a specifieddestination. In some embodiments, each transit leg of a transit routeincludes a section of the transit route that is travelled by a transitvehicle of a transit line. A transit leg may also include a walkingdistance that is more than a threshold distance.

In examining the transit legs, the application of some embodiments takesinto account a set of transit preferences that are customized (i.e., setor adjusted) by the user. For instance, in some embodiments, a user mayadjust the date and time of the departure (from, e.g., the currentlocation of the user) to a particular date and time instead of thecurrent time. Conversely, the user may prefer a particular type oftransit vehicle (i.e., a transit vehicle of a particular transit system)over the other types. For example, the user might rather ride a subwaytrain over a bus for a particular transit leg of a transit route, or useonly ground transportation for an entire transit route (e.g., a transitroute without any ferry trips).

Based on the examination of the transit legs, the map applicationidentifies one or more transit routes that use one or more transitvehicles of one or more transit systems in some embodiments. Theidentified routes may also include one or more pedestrian routes thatare between the different transit trips, between the starting locationand the first transit trip, and between the last transit trip and thedestination location. After identifying the transit routes, the mapapplication selects one of the identified transit routes based on a setof criteria (e.g., fastest route, shortest route, route with leastamount of walking, route requiring least amount of transit vehiclechanges, route requiring least amount of transit system changes, etc.),and displays this selected route over the map presentation. In someembodiments, the selection criteria set relies on two or more selectionparameters. Also, in some embodiments, the selection criteria set isdifferent in different transit markets and/or in different time periodsin the same transit market.

The map application of some embodiments displays the best identifiedroute in its entirety over a portion of a map presentation of ageographical area. The application of some such embodiments displays theidentified route in multiple sections (transit legs) each of which istraveled by a particular transit vehicle. The map application usesdifferent graphical representations for different portions of adisplayed transit route that are travelled by different types of transitvehicles or require walking. In some embodiments, the different types oftransit vehicles that are presented by different graphicalrepresentations include buses, subway trains, rail trains (e.g., lightrail trains and heavy rail trains), and ferries. Each of these fourcategories may include multiple different subcategories in someembodiments. When the selected transit route includes multiple transitvehicles of the same type (same transit system), each transit vehicle ofthe same transit system is distinguished from the other transit vehiclesby a different line of the transit vehicle (e.g., a different subwayline, a different bus line, etc.).

Several detailed embodiments of the invention are described below.Section I describes transit navigation mode of a map application of someembodiments. Section II then describes characterization of transit linesbased on departure frequency. Section III follows with a description ofa method for computing departure frequencies. Section IV describesexample electronic systems with which some embodiments of the inventionare implemented. Finally, Section V describes a map service operatingenvironment.

I. Transit Navigation Mode

FIG. 1 illustrates a map application that provides transit navigationpresentations of some embodiments of the invention. In some embodiments,the map application executes on a mobile device (e.g., a smartphone, atablet, a laptop, etc.) with a touch-sensitive display screen. Although,all the features and concepts of the map application discussed below areequally applicable to other devices with non-touch-sensitive displayscreens. The map application can operate in a map-browsing mode to allowa user to browse a map of a locality and to perform searches for maplocations based on addresses, names (e.g., people, businesses, etc.) orother search parameters. The application also has a navigation mode thatincludes a driving navigation mode to provide driving navigationdirections, a walking navigation mode to provide walking navigationdirections, and a transit navigation mode to provide transit navigationdirections.

FIG. 1 illustrates, in four operational stages 105-120 of the userinterface (UI) 100 of the map application, how the transit navigationmode of the map application can be selected by requesting for a routefrom the current location of the user to a searched destination. Theapplication then displays a route that is travelled by a combination oftwo different transit vehicles (of two different types) between thecurrent location of the user and the searched destination. Someembodiments provide the user with a search box to search for aparticular location. The user may then enter an address of a particularplace or alternatively a name of the place in the search box. When theaddress (or name) of the place is specified, the map application of someembodiments provides an indicator (e.g., a pin) over a presentation ofthe map to display the exact location of the place on the mappresentation. In addition, some such embodiments display a banner (e.g.,over the pin) with selectable controls for providing more informationabout the place.

The first stage 105 of FIG. 1 illustrates a search box 125, a mappresentation area 130 that displays a map of a geographical area, a pin135, and a banner 140. The banner 140 includes a selectable routecontrol 145 (which is depicted as a presentation of a car), a name 150of the searched place, and a selectable control 155 (which is depictedas a right arrow). In the search box 125, a user can enter a searchparameter to search for a particular location for display in the mappresentation area 130. In some embodiments, the search parameter can bean address or a name of an entity (e.g., business, organization, person,etc.), or some other parameter. When the map application can identifyone or more locations for the search parameter that it receives, the mapapplication in some embodiments (1) displays, in the presentation area130, a map that displays some or all of the identified locations, and(2) displays a pin 135 or other location indicator for each displayedlocation to identify the position of the identified location. Also, insome embodiments, the map application displays a banner 140 over one ofthe pins 135 for providing access to more information about the locationidentified by the pin. The banner also provides some information aboutthe identified location.

The first stage 105 of the figure shows that the user has entered anaddress in the search box 125 (123 A Street). As a result, theapplication displays, in the map presentation area 130, a map of aparticular geographical area in which the entered address is located.This stage also shows that the application further displays (1) the pin135 over the map presentation to identify the location of the enteredaddress on the map and (2) the banner 140 over the pin. As shown, thisbanner includes the address “123 A Street,” the route control 145, andthe selectable control 155, which when selected causes the mapapplication to present a display area (e.g., a placecard) that providesmore information about the identified location.

The second stage 110 illustrates that the user selects the selectableroute control 145 (e.g., by performing a gestural input on thetouch-sensitive display screen of the device, such as tapping the user'sfinger on the control 145). Selection of the route control 145 causesthe application to display a route overview (e.g., a driving route) fromthe current location of the user to the searched location (i.e., to thepin 135) over the map presented in the map presentation area 130. Insome embodiments, the route control 145 is also for initiating anavigation experience. For instance, the map application of someembodiments provides one or more routes to the location of the pin fromthe current location of the device upon receiving a selection of theroute control. When a route is selected, the map application can startoperating in a navigation mode or in a route inspection mode dependingon the user's next selection.

The third stage 115 shows that the displayed route 175 is laid over theregion map. The third stage 115 also shows three navigation modecontrols, which are the driving mode control 178, the walking modecontrol 180, and the transit mode control 182. Through these controls,the user can direct the map application to provide one or more drivingroutes, walking routes, and transit routes from the specified startinglocation (i.e., the device's current location in this example) to thespecified destination (i.e., to 123 A Street in this example). The thirdstage 115 shows the driving mode control 178 highlighted to indicatethat the route 175 that the application initially provides is a drivingroute. In some embodiments, the map application dynamically determineswhether to provide an initial driving, walking or transit route based onthe distance to the destination, the locality in which the devicecurrently operates, and the detected current mode of transportation forthe device (if any).

The map application of some embodiments makes a dynamic determinationfor the default mode of navigation based on a set of motion data that itreceives through the different sensors of the device and a set of rulesthat specifies the default mode of navigation under different detectedconditions. For instance, the application detects the current useractivity (e.g., driving, walking, biking, etc.) from motion data thatsome detecting sensors of the device collect and based on the determinedactivity, automatically sets the default navigation mode to thepedestrian mode (i.e., walking mode) or driving mode. For instance ifthe application determines, based on the motion data it receives fromthe motion sensors, that the user of the device is in a vehicle, theapplication sets the default navigation mode to driving mode (asillustrated in this example).

In some embodiments, the map application uses a combination of themotion data that it receives through the motion sensors, and thedistance to the desired destination in order to determine whichnavigation mode should be the default mode. For instance, in someembodiments, the application does not set the default mode to thepedestrian mode when the destination location is not within a thresholddistance (e.g., two miles) from the current position of the user even ifthe motion data indicate that the user is walking Conversely, theapplication of some embodiments does not set the default mode to thedriving mode when the destination location is within a thresholddistance (e.g., 0.5 miles) from the current position of the user and themotion data indicate that the user is not driving.

The third stage also shows that for the displayed route, the mapapplication provides information about the route in a display area 183.For instance, in the driving mode, the display area 183 displays thedriving distance and duration to the destination from the currentlocation of the device. The third stage also shows that theroute-overview presentation includes a start control 184 for starting aturn-by-turn navigation experience to the destination based on thecurrently selected navigation mode (e.g., driving mode, walking mode, ortransit mode). For example, when the map application is displaying atransit route overview presentation in the transit mode, selection ofthe start control 184 directs the map application to start a transitnavigation presentation that provides transit navigation directions fromthe device's current location to the destination. Navigating a transitroute is described is great detail in the concurrently filed U.S. patentapplication Ser. No. 14/869,570 entitled “Transit Navigation”, which isincorporated herein by reference.

The third stage shows that the user selects the transit control 182(e.g., by tapping on the tab 182) to change the navigation mode of theapplication from a driving navigation mode to transit navigation mode.Upon receiving this request, the map application of some embodimentsidentifies one or more transit routes to the specified destination,selects one of the identified transit routes as the best possibletransit route based on a set of criteria, and displays the selectedtransit route 189, as shown in the fourth stage 120.

The map application of some embodiments, upon receiving a request todisplay a route in transit mode, identifies the best possible transitroute among several different routes between two locations and displaysthe route to the user. Specifically, to identify the transit routes, theapplication of some embodiments examines trips that one or more transitvehicles of one or more transit systems make from locations nearby aspecified starting location (e.g., the current location of the device)to locations near the specified destination. Based on this examination,the application identifies one or more transit routes that use one ormore transit vehicles of one or more transit systems in someembodiments.

After identifying the transit routes, the map application then selectsone of the identified transit routes based on a set of criteria (e.g.,fastest route, shortest route, route with least amount of walking, routerequiring least amount of transit vehicle changes, route requiring leastamount of transit system changes, etc.), and displays this identifiedroute over the map presentation in the presentation area 130. In someembodiments, the selection criteria set relies on two or more selectionparameters. Also, in some embodiments, the selection criteria set isdifferent in different transit markets and/or in different time periodsin the same transit market.

Although in the descriptions above and below, the map application isidentified as the performer of actions such as identification andranking of the transit routes, in some embodiments some or all of theseactions are performed by a mapping service, which then provides theresults to the map application. For instance, in some embodiments theidentification of different transit routes and selection of the bestpossible route among the identified transit routes is done by a mappingservice that runs on one or more dedicated servers.

The mapping service of some embodiments is the same mapping service thatprovides other map browsing and navigation data (e.g., routing data,traffic data, map tiles, etc.) to the map application. In some otherembodiments, the mapping service is a designated service for providingtransit data to the map application. The mapping service of someembodiments receives a request for transit routes, which includes thestarting and destination locations. The service then identifies a set ofavailable transit routes based on the user preferences, ranks theidentified transit routes based on a set of criteria, and returns theranked identified transit routes to the map application. The mapapplication then displays the highest ranked transit route as theselected transit route in the transit navigation mode to the user.

In some embodiments, the application ranks the identified routes basedon the set of criteria and some other factors. For instance, theapplication initially ranks the identified routes with the shortesttransit route having the highest ranking. The application then requestsfor and receives real time incident (e.g., traffic) data for theidentified routes (e.g., from a set of dedicated servers, from adesignated incident curator that gathers incident data from differentsources, etc.). Based on the received data, the application of someembodiments rearranges the routes and ranks them again for a secondtime. The application then displays the highest ranked (secondaryranked) transit route in the route presentation area. In someembodiments, as discussed above, a mapping service identifies and ranksthe transit routes. In some such embodiments, the mapping servicerequests the real time incident data from dedicated servers in order torank the transit routes. In some embodiments, the mapping servicegathers and maintains the incident data directly (e.g., through anincident curator module of the mapping service).

The fourth stage 120 illustrates that the route 175 in the previousstage 115, is now replaced by a transit route 189 as a result ofselecting the transit navigation mode as the operational mode of theapplication. The preferred criterion in this example is the least amountof walking and therefore the transit route shown in the figure isselected as the best transit route because it includes the minimalwalking distance between the departure point, the transit stations, andthe destination point.

In addition to a predefined set of criteria, the application of someembodiments selects the best possible route based on a set of transitpreferences set by a user. The user in some embodiments customizes theapplication by setting or adjusting a set of transit preferencesprovided by the map application. For instance, in some embodiments, auser may adjust the date and time of the departure to a particular dateand time instead of the current time. In some embodiments, the user mayprefer a particular type of transit vehicle (i.e., a transit vehicle ofa particular transit system) over the other types. For example, the usermight rather ride a subway train over a bus in a particular transittrip, or use only ground transportation for an entire transit route(e.g., a transit route that does not include a ferry trip). Customizingthe route selection is further described in the concurrently filed U.S.patent application Ser. No. 14/869,403 entitled “Map application withTransit Navigation Mode”, which is incorporated herein by reference.

Some embodiments display the best route in its entirety over a portionof a map of a geographical area. Some such embodiments display the routein multiple sections each of which is traveled by a particular transitvehicle. In some embodiments, the map application uses differentrepresentations for different portions of a displayed transit route thatare travelled by different transit vehicles or require walking. Thedisplayed transit route in the fourth stage 120 includes two differentportions 185 and 187. The first portion (leg) of the transit route(i.e., the route portion 185) is travelled by a bus, while the secondportion (i.e., the route portion 187) is travelled by a subway train.The two portions are displayed by two different graphicalrepresentations (e.g., a bus route representation for the bus portionand a rail representation for the train portion) to differentiate thebus and subway portions from each other. In the discussions below, atransit leg refers to a portion of a transit route that starts or endswith a transit maneuver that requires a transit vehicle change or awalking portion with a minimum threshold distance in a transit route.

In the illustrated example, two small walking portions 197 and 199 arealso displayed. Specifically, the walking portion 197 represents thewalking distance from the current location of the device (user) 196 tothe first transit station (i.e., the first bus stop of the transitroute). The second walking portion 199 represents the walking distancefrom the last transit station (i.e., the last subway station of thetransit route) to the destination location. Although these walkingportions are part of the path that the user of the device travels toreach the destination, as will be discussed in more detail below, theyare not considered as separate legs of the transit route in someembodiments. Some such embodiments identify a walking portion of atransit route as a transit leg of the route only if the walking distanceis equal to or more than a threshold length (e.g., more than half amile, more than one mile, etc.). Any walking portions less than thethreshold will not be identified as a walking leg of the transit routein these embodiments.

In some embodiments, the different types of transit vehicles that arepresented by different graphical representations include buses, subwaytrains, rail trains (e.g., light rail trains and heavy rail trains), andferries. Each of these four categories may include multiple differentsubcategories in some embodiments. For example, the bus category mayinclude single-deckers, double-deckers, rigid buses, articulated buses,etc. that are provided by the same or different bus service providers.As another example, a light rail train may include many different typesof city trains such as streetcars, trams, trolleys, etc. that areprovided by the same or different light rail service providers.Additionally, the best route may include multiple transit vehicles ofthe same type (same transit system) in some embodiments. In such a case,each transit vehicle of the same transit system is distinguished fromthe other transit vehicles by a different line of the transit vehicle.For example a transit route may include three different bus legs thatare serviced by three buses of three different bus lines.

The display area 183 of the third stage 115 is divided in the fourthstage 120 into two display areas 190 and 193. The incident display area190 currently shows the arrival time at the destination. However, thisdisplay area is also for displaying various other transit informationthat can help the user to plan the transit trip more easily. Displayingdifferent transit information in the display area 190 is furtherdescribed in the concurrently filed U.S. patent application Ser. No.14/869,694 entitled “Transit Incidents”, which is incorporated herein byreference. A few examples of this additional transit information include(1) any incident that has occurred along the displayed transit route,(2) an incident that has occurred along another route which has causedthe displayed route ranked better than the other route, (3) departuretime or frequency of departures for the first leg of the transit route,and (4) departure frequency of the entire route.

The display area 193 is for displaying a route summary presentation forthe displayed transit route. More specifically, this display area showsa different representation for each transit vehicle for each leg of thetransit route along with the line of the transit vehicle. As illustratedin this example, the display area 193 currently shows a representationfor a bus of the line 125 that travels the first leg of the transitroute and a representation for a subway train of the line 166 thattravels the second leg of the transit route.

Each representation for a transit vehicle, in the illustrated example,includes a logo that represents the type of the transit vehicle (e.g., abus logo, a subway train logo, etc.), and a geometric shape that (1)includes the line of the transit vehicle and (2) is different fordifferent types of transit vehicles (e.g., a rectangle for bus lines, anellipse for subway lines, etc.). However, one of ordinary skill in theart would realize that the different types of transit vehicles could berepresented in different embodiments differently. For example someembodiments provide different colors for the different representationsto distinguish them from each other while other embodiments providedifferent graphical shapes that represent different types of transitvehicles.

The fourth stage 120 also shows a selectable More Routes control 195 forshowing more routes. As discussed above, the displayed transit route isthe best transit route that the application selects among a set ofdifferent routes based on a set of different criteria as well as a setof user preferences. Selecting the control 195 causes the application toshow the other routes in the set of different routes in a separatedisplay area. Displaying all the identified transit routes andinteracting with the route representations are further described in theconcurrently filed U.S. patent application Ser. No. 14/869,403 entitled“Map application with Transit Navigation Mode”,.

II. Characterizing Transit Lines Based on Departure Frequencies

In some embodiments a transit line is characterized as a high frequencyor a low frequency transit line based on the number of departures of thetransit vehicles of the line from a particular transit station during aparticular period of time. Similarly, in some embodiments a transitvehicle of a particular line is characterized (1) as a high frequencytransit vehicle when the transit vehicle belongs to a high frequencyline, and (2) as a low frequency transit vehicle when the line of thevehicle is a low frequency transit line.

Accordingly, in some embodiments, a first transit line (e.g., a firstbus line) can be characterized as a low frequency transit line at aparticular transit station, while a second, different transit line (e.g.a second bus line) can be characterized as a high frequency transit lineat the particular transit station. Conversely, in some embodiments, atransit line can be characterized as a high frequency transit line at aparticular transit station during a first time period (e.g., on evendays of the week, in the mornings, between two particular hours, etc.),while the same transit line can be characterized as a low frequencytransit line at the same particular station but during a seconddifferent time period (e.g., on odd days of the week, in the evenings,between two particular hours, etc.).

The map application of some embodiments treats the high frequencytransit lines differently than the low frequency transit lines. As oneexample, the application presents the departure times of high frequencytransit vehicles in a first manner while it presents the departure timesof low frequency transit vehicles in a second different manner indifferent display areas of the UI of the application. Additionally, theapplication of some embodiments classifies high frequency transit linesinto different classes and presents the frequency of departure for eachclass differently.

In some embodiments, categorizing the transit lines into high and lowfrequency lines and computing the frequency of departures of aparticular transit line are done by a mapping service that runs on oneor more dedicated servers. In some embodiments the mapping service isthe same mapping service from which the map application receives thedifferent mapping data (e.g., road data, traffic data, etc.) and routingdata. In some embodiment the map application computes the departurefrequencies, while in other embodiments part of the departurefrequencies is computed by the device on which the map applicationexecutes and the other part of the departure frequencies is receivedfrom one or more mapping services.

In order to determine the frequency of departures of a transit line froma transit station during a particular time period, the mapping serviceof some embodiments first determines whether the transit vehicles of theline depart from the transit station on average at least once during acertain time period (e.g., 30 minutes). This certain time period can bedifferent in different areas or for different transit lines of the sameor different transit systems. When the mapping service of some suchembodiments determines that the vehicles of the transit line depart atleast once during the certain time period, the service categorizes thetransit vehicles of the line as high frequency transit vehicles. Themapping service then calculates the frequency of departures for highfrequency transit lines.

For example, in order to determine whether a bus line at a bus stop is ahigh frequency line or a low frequency line, the mapping servicedetermines whether a bus of the line departs from the bus stop every N(e.g., 25) minutes for the next M hours (e.g., 3 hours). If there is atleast one bus that departs from the stop in every N minutes for the nextM hours, the mapping service categorizes the bus line as a highfrequency line at the station for the next M hours. In some embodimentsthe mapping service makes such a determination based on the transit datathat it receives from one or more transit service providers. In someembodiments, the mapping service periodically requests for orautomatically receives the transit data from the transit serviceproviders while in other embodiments the mapping service requests thetransit data when it receives a request (e.g., from a map application)for departure frequency of a line.

In order to compute the frequency, the mapping service of someembodiments first identifies the time intervals between each pair ofdepartures of the transit vehicles of the line that head the samedirection from the same transit station during a particular time period.The service then applies a series of mathematical functions and formulasto the identified numbers (i.e., the sequence of the gaps between thedeparture times) in order to calculate the frequency of departures forthe line. In some embodiments the calculated departure frequency can bea number that represents the exact frequency of departures (e.g., every5 minutes), a number that represents an approximation of frequency ofdepartures (e.g., about every 5 minutes), or a range of numbers (e.g.,every 5-8 minutes). Some embodiments first determine whether an exactfrequency can be used, then determine (if no exact frequency is found)whether one of a set of frequency ranges can be used, and only attemptto find an approximate frequency value if the first two options areunsuccessful.

Depending on the frequency category of a transit line at a transitstation, the map application of some embodiments displays the departureschedule of the transit line in a different format on different displayareas of the UI of the application (e.g., on placecards, navigationbanners, etc.). For example, for a high frequency transit line, the mapapplication displays the departure time of the line in a frequencyformat. That is, the application displays the frequency of departures ofthe transit vehicles of the line (e.g., every 5 minutes, 5-10 minutes,etc.) from the transit station. For a low frequency transit line,however, the map application of some such embodiments displays thedeparture time in an absolute time format. That is the map applicationdisplays the time at which the transit vehicles of the line leave thestation (e.g., at 2:30 pm, at 3:30 pm). In some embodiments, theapplication displays only one frequency of departures for a highfrequency line (e.g., under the trip heading in a placecard), while itdisplays multiple departure times for the next transit vehicles of a lowfrequency line (e.g. the next three departure times of a train lineunder the trip heading of the line).

FIG. 2 conceptually illustrates a process 200 that some embodimentsperform to provide departure schedule of a transit line. In someembodiments, this process is performed by the mapping service asdescribed above while in other embodiments the process is formed by themap application. The process 200 is initiated by categorizing (at 210)the transit line as either a high frequency transit line or a lowfrequency transit line. As described above, some embodiments categorizea transit line as a high frequency transit line when the transitvehicles of the line depart from a particular transit station on averageat least once during a certain time period (e.g., 30 minutes) in acertain duration of time (e.g., 2 hours). Otherwise some suchembodiments categorize the line as a low frequency transit line.

The process then determines (at 220) whether the transit line is a highfrequency transit line or low frequency. When the process determinesthat the transit line is high frequency, the process computes (at 230)the departure frequency of the transit line. As described above andbelow, the process of some embodiments computes the departure frequencyof the line by determining whether a collection of successive gaps inthe departure times of the transit line from a particular transitstation can be expressed by (1) a single exact number, (2) a singleapproximate number, or (3) a pair of numbers that describe the range ofgaps between successive departure times.

After computing the departure frequency of the high frequency transitline, the process 200 provides (at 240) the computed frequency (e.g.,“every 5 minutes,” “about every 10 minutes,” or “4-8 minutes”) as thedeparture schedule of the transit line. The process then ends. Theprocess of some embodiments provides the departure frequency to bedisplayed in different display areas of the map application. For examplethe departure frequency can be displayed, as the departure schedule of atransit line, in a transit station's placecard from which the transitline departs, in the navigation banner that shows navigation instructionrelated to the transit line, etc. On the other hand, when the processdetermines (at 220) that the transit line is a low frequency transitline, the process determines (at 250) whether the device is closer thana threshold distance to the transit station at which the departureschedule of the transit line was sought to be displayed.

When the process determines that the device is closer than the thresholddistance, the process provides (at 260) the departure time of thetransit line's next transit vehicle. That is, the process provides(e.g., in the transit station's placecard, in the navigation banner,etc.) an absolute departure time at which the next transit vehicle ofthe line leaves the transit station (e.g., “Departs at 2:30 pm,” etc.).The process then ends.

Alternatively, when the process determines that the device is outsidethe threshold distance from the transit station, the process provides(at 270) the departure time from current location of the device. Thatis, the process provides (e.g., to be displayed in a route planningdisplay area, in a navigation banner, etc.) the time by which the usershould leave the current location to be able to board the next transitvehicle of the line at the transit station. As discussed above, someembodiments, display only one frequency of departures for a highfrequency line (e.g., under the trip heading in a placecard), whilethese embodiments display several departure times for the next transitvehicles of a low frequency transit line (e.g. the next three departuretimes of a train line under the trip heading of the line at the trainstation). The process then ends.

Some embodiments perform variations of the process 200. The specificoperations of the process 200 may not be performed in the exact ordershown and described. Additionally, the specific operations may not beperformed in one continuous series of operations, and different specificoperations may be performed in different embodiments. For example, theprocess of some embodiments displays one or more countdowns to the nextdeparture times of a transit line next to the computed frequency whenthe process displays the computed frequency.

As stated above, in addition to the category of frequency (i.e., highfrequency or low frequency), the map application displays the departureschedules of transit lines based on other factors as well. For instance,in some embodiments, the map application displays different formats fordeparture schedules based on the frequency category as well as theposition of the device in relation to the transit station. FIGS. 3 and 4illustrate different formats of displaying the departure schedules oftransit vehicles from a transit station based on the frequency categoryof the transit vehicles and based on the position of the device. Morespecifically, FIG. 3 illustrates the UI 300 of the map application ofsome embodiments that displays the departure schedule of a subway trainfrom a subway station in terms of three different examples 305-315.

In the first example 305, the map application UI 300 shows the besttransit route 320 to an address (i.e., 345 B Street) drawn over apresentation of a map in the map presentation area 130. The currentdevice's location 325 is also shown on an area of the map presentationthat is relatively far from the subway station 330. The route summarydisplay area 193 displays a walking person representation for thewalking leg of the trip and a subway train representation that travelsthe subway leg of the transit route 320. The display area 193 in thisexample also shows that the total trip time from the current position ofthe device to the address is 1.6 hour (1 hour and 36 minutes) whichincludes a total walking distance of 1.2 miles. The first example 305further shows that the display area 390 displays a departure schedule ofevery 5-10 minutes for the subway train line 166 which takes the user(passenger) to the destination address.

The illustrated example shows, in the display area 390, the frequency ofdepartures of the subway trains of line 166. In this example though, thesubway train of line 166 is the only high frequency transit vehiclerequired to reach the destination. Different embodiments show differentschedules in the display area 390 based on the number of legs of thetrip and based on whether each leg of the tip is traveled by a highfrequency transit vehicle or a low frequency transit vehicle. In someembodiments, the map application provides the frequency of departures ofthe first transit vehicle that travels the first leg of the trip whenthere is a combination of high and low frequency transit vehiclestraveling different legs of the transit route.

In some other embodiments, when all the transit vehicles of the transitroute are high frequency transit vehicles, the map application providesa total frequency of departures of the trip. That is, in some suchembodiments, the application calculates the transit route frequencybased on different sequence of departure gaps in each leg of the transitroute, and then provides the transit route frequency (i.e., totalfrequency of departures of the lines that are used in the transit route)in the display area 390. The method of computation of the departurefrequency of a transit route of some embodiments is described in detailbelow by reference to FIGS. 10 and 11.

The second example 310 of FIG. 3 shows the best transit route 340 toanother address (i.e., 567 C Street) drawn over the map presentation inthe map presentation area 130. The current device's location 325 in thisexample, however, is at or very close to the subway station 330. As aresult, the route summary display area 193 does not display a walkingperson representation for any walking leg of the trip. Instead thisdisplay area only includes a subway train representation that travelsthe subway leg of the transit route 340. The display area 193 in thisexample also shows that the total trip time from the current position ofthe device to the address is 25 minutes and includes a total walkingdistance of only 0.1 miles. The second example 310 further shows thatthe display area 390 displays a departure schedule of every 5 minutesfor the subway train line 188 which takes the user (passenger) to thedestination address in this example.

The third example 315 shows the same UI of the second example 310 withthe same transit route 340 to the same address (i.e., 567 C Street). Thecurrent device's location 325 in this example is also at the subwaystation 330. However, in this example the time of day is 11:30 pm,whereas the time of day in the second example was 1:20 pm. The displayarea 193 at this example also shows that the total trip time from thecurrent position of the device to the address is 25 minutes and includesa total walking distance of only 0.1 miles. The third example 315,however, shows that the display area 390 now includes a departureschedule of “about every 13 minutes” for the same subway line 188. Thisis because the subway line at this time of the day has fewer departuresfrom the transit station compares to earlier in the afternoon. Thereason for displaying the departure frequencies in a different format ineach of the above-described examples (i.e., “every 5-10 minutes,” “every5 minutes,” and “about every 13 minutes”) is described below in detailsby reference to FIGS. 7 and 9.

FIG. 4 illustrates the UI 400 of the map application of some embodimentsthat displays the departure schedule of a train (e.g., a light railtrain) from a train station in terms of two different examples 405 and410. As described above, the map application of some embodiments groupsdifferent transit vehicles into high frequency transit vehicles and lowfrequency transit vehicles. The application looks at the departureintervals of the transit vehicles of a line from a station and if theintervals are greater than a threshold (e.g., 30 minutes), theapplication groups those transit vehicles as low frequency transitvehicles. In this example, the intervals between departures of everytrain of line E from the train station is an hour, hence the trains ofthis line are categorized as low frequency trains.

In the first example 405, the map application UI 400 shows the besttransit route 420 to an address (i.e., 789 D Street) drawn over apresentation of a map in the map presentation area 130. The currentdevice's location 425 is also presented on an area of the mappresentation that is relatively far from the train station 430. Theroute summary display area 193 displays a walking person representationfor the walking leg of the trip and a train representation that travelsthe train leg of the transit route 420. The display area 193 in thisexample also shows that the total trip time from the current position ofthe device to the address is one hour and 45 minutes which includes atotal walking distance of 1.4 miles. The first example 405 further showsthat the display area 490 displays the time by which the user shouldleave the current location of the user (i.e., 1:35 pm) to be able tocatch the next train of line E which takes the user (passenger) to thedestination address.

As described above, the map application of some embodiments canintelligently guide the user to plan for a transit trip based on theuser's location. The map application of some such embodiments firstidentifies the location of the device on which the application runs. Theapplication then evaluates the distance between the device and the firsttransit station at which the user boards the first transit vehicle. Whenthe application realized that the user is far away from the transitstation (e.g., farther than a threshold distance), the applicationdisplays the time by which the user should starts the transit trip(i.e., the user should leave the current location towards the firsttransit station). On the other hand, when the user is at or near thetransit station (e.g., closer than the threshold distance), theapplication displays the time at which the first transit vehicle of theline leaves the transit station.

The second example 410 shows the same transit route 420 to thedestination address as in the first example, drawn over the mappresentation. The current device's location 425 is, however, very closeto the train station 430 in this example (the device is shown almost atthe transit station). The route summary display area 193 does notdisplay a walking person representation in example 410 and only showsthe train representation that travels the train leg of the transit route420. The display area 193 in this example also shows that the total triptime from the current position of the device to the address is 45minutes which includes a total walking distance of 0.1 miles. The secondexample 410 further shows that the display area 490 displays the time atwhich the first train of line E is scheduled to depart from the trainstation (i.e., 2:30 pm). This is because, in this example, the mapapplication has identified that the user is within the vicinity of thetrain station and therefore it shows the departure time of the traininstead of the time at which the user should leave the her currentlocation.

In addition to providing transit departure schedules in a transit routeplanning UI such as the display area 190 in the above examples, the mapapplication of some embodiments provide detailed transit information fora particular transit station when the particular transit station isselected. In some embodiments, when a user selects a transit station ona map view (e.g., by tapping on a selectable representation of thestation that is displayed on a map presentation), the map applicationprovides a display area (transit placecard) that includes variousinformation about the transit station and the different transit linesthat depart from the transit station. For instance, the map applicationof some such embodiments provides the name and address of the transitstation as well as the departure schedule of the different transit linesfrom the transit station. Transit placecards are further described inthe concurrently filed U.S. patent application Ser. No. 14/869,706entitled “Map application with Transit Navigation Mode”, which isincorporated herein by reference.

FIG. 5 illustrates how a user can access and view a transit stationplacecard that provides transit schedules related to the transitstation. More specifically, this figure shows, through four operationalstages 505-520 of the map application UI, a user selecting a particulartransit station that is displayed on a map of a geographical area. Theuser can then view the departure schedule of all of the transit vehiclesthat stop at the particular transit station. The map application of someembodiments takes into account the locality in which the transit stationis located as well as the type of the transit vehicles (e.g., to whichtransit system the transit vehicles belong) in providing the informationin the departure schedule.

The first stage 505 shows a map application UI that includes arepresentation of the best identified route that is drawn over a portionof the map presentation. The identified transit route includes twodifferent bus legs 570, a walking portion 575, and a subway leg 580.This stage also shows that the route summary display area 193 displays atransit route summary representation that includes a bus representationfor the bus of the line 56, a walking person representation for thewalking portion, a bus representation for the bus of the line 244, and asubway train representation for the subway leg 580 of the transit route.The incident display area 190 displays an incident report that informsthe user an accident is delaying one of the two bus lines used in thetransit route.

The second stage 510 shows that the user selects the last transitstation 525 of the displayed transit route. In some embodiments eachtransit station for which a transit station placecard is available ispresented on a map with a selectable transit station representation. Insome other embodiments, the map application displays a transit stationrepresentation for every transit station that is displayed on the mappresentation. In yet other embodiments, the map application does notdisplay any transit station representation over the map presentation andselecting the transit station (e.g., by tapping on the display area overthe map presentation at or around the area that the transit station islocated) would cause the map application to display a transit stationplacecard for the selected transit station. In some such embodiments,selecting the transit station on the map directs the application toprovide a banner similar to the banner displayed for the destination inthis stage. The user can then select the transit station placecard byselecting the corresponding control on the banner (e.g., the right arrowdepicted on the right hand side of the banner for “123 A Street”destination).

The third stage 515 illustrates that the map application, in response tothe selection of the subway station 525, displays a display area 530 forthe transit terminal placecard which includes general information aboutthe transit station (i.e., subway station 525) as well as the departureschedule of the transit vehicles (i.e., subway trains) of differentlines. Although in the illustrated embodiment, the general informationonly includes the name and address of the transit station, some otherembodiments provide a variety of information about the transit stationin the transit station placecard. For instance, the map application ofsome embodiments provides information such as directions to and/or fromthe station, images of the station (e.g., from both inside and outsidethe station), the reviews gathered by information aggregation entities(e.g., Yelp, Facebook, Twitter, etc.) about the transit station, etc.

The third stage also shows the departure schedule for all subway trainsthat leave the station in the Uptown direction. More specifically, thisstage shows a trip heading 540 for all the trains that travel north(i.e., in the Uptown direction), a line number 545 for each train, afrequency of departure 550 of each train, and a countdown 555 to thenext scheduled train's departure. The map application of someembodiments identifies a local directional term for every cardinaldirection towards which a set of transit vehicles travel (if such a termis available). The map application of some such embodiments identifiesthese terms based on the geographical area in which the transit stationlocated (e.g., the terms that are used in a certain locality). The mapapplication then displays the identified term as a header for the set oftransit vehicles that travel in each particular direction. Labelingtransit directions with local directional terms is described in furtherdetail in the concurrently filed U.S. patent application Ser. No.14/869,403 entitled “Map application with Transit Navigation Mode”.

In the illustrated example, the term that is used (e.g., by thepassengers and transportation system of this particular geographicalarea in which the subway station located) for the north is “Uptown.”Hence the map application has identified and displayed Uptown as aheader for the subway trains that travel northbound from the subwaystation. Under the header, the map application lists subway trains ofthe lines that are scheduled to depart from the subway station in thespecified direction. That is, the map application of some embodimentsdisplays a list of subway lines, the trains of which will leave thesubway station during a certain time period from the current time (e.g.,the subway trains that leave the station in the next 15 minutes). In theshown example of stage 515, three different subway trains of the lines15, 56, and 99 will leave the station in the Uptown direction in thenext 7 minutes from the current time of the device (i.e., 1:20 pm).

The frequency of departure 550 of each train in the third stage 515,shows the time intervals at which a next train of the line leaves thesubway station. The map application of some embodiments, provides, inthe transit placecard of a transit station, a departure time for eachtransit vehicle of a transit line in a particular format. The mapapplication of some such embodiments categorizes the transit lines intotwo categories of high frequency transit lines and low frequency transitlines. Depending on the category of the transit line the map applicationdisplays the departure time of the transit vehicles of that line in adifferent format. For a high frequency transit line, the map applicationdisplays the departure times in a frequency format, which includes thefrequency of departures of the transit vehicles of the line from thestation. For a low frequency transit line, the map application displaysthe departure times of the transit vehicles of the line in an absolutetime format, which includes the time at which the transit vehicle leavesthe station.

In order to determine whether a transit line is high frequency or lowfrequency, the map application of some embodiments first evaluates thefrequency of departures of the transit vehicles of the line from atransit station. The application then determines whether the evaluatedfrequency is greater than a threshold (e.g., a predefined time period).When the evaluated frequency is greater than the threshold, the mapapplication of some such embodiments categorizes the transit vehicle asa low frequency transit vehicle. On the other hand, when the evaluatedfrequency is less than or equal to the threshold, the map applicationcategorizes the transit vehicle as a high frequency transit vehicle.

In the illustrated example, the map application has categorized thesubway trains of this line at this particular subway station as highfrequency transit vehicles. As such, the departure schedule of thesubway train of line 15 is displayed in frequency format (i.e., every 5minutes). Similarly, the map application has determined that subwaytrains of the line 99 are high frequency trains at this station.Consequently, the departure schedule of the subway train of line 99,although different from the subway trains of line 15, is displayed infrequency format as well (i.e., every 10 minutes). Some embodimentsprovide a novel method of calculation of the frequency of departures ofthe transit vehicles of different lines from different transit stations.The method of calculation of the frequencies of departures of differenttransit vehicles is also described in details below by reference toFIGS. 7-9.

The third stage 515 further shows a countdown 555 to the next scheduledsubway train's departure of each subway line. The map application ofsome embodiments provides a countdown to the next scheduled transitvehicle's departure in order to provide a more precise time of departureto the user. The combination of the countdown and the frequency providesthe user with all the information needed for the departure schedule of atransit vehicle. In other words, a user would realize how long more theuser has to wait for the next train of the line by looking at thecountdown information. At the same time, the user would know how muchmore the user has to wait if he misses the next train by looking and thefrequency of the departures.

Lastly, the third stage shows that the user is scrolling up theinformation displayed in the transit station placecard in order to viewother transit information provided by the placecard. Consequently, auser, with a glance at the illustrated placecard, would realize thatthree different subway trains of the lines 15, 56, and 99 will leave thestation in the Uptown direction in the next 7 minutes from the currenttime of the device (i.e., 1:20 pm). The subway trains of subway lines 15and 56 depart towards Uptown every 5 minutes while the subway trains ofthe line 99 departs towards Uptown every 10 minutes. The next scheduleddeparture for the subway line 15 will be in 2 minutes, the nextscheduled departure for the subway line 56 will be in 4 minutes, and thenext scheduled departure for the subway line 99 will be in 7 minutes.

The fourth stage 520 shows the transit station placecard displayingadditional departure information after scrolling the information up. Thedisplay screen 530 now displays the Uptown departure schedule under thetrip heading 540, as well as the schedule for the subway trains thatdepart towards Downtown. More specifically, this stage shows a tripheading 560 for all the trains that travel south (i.e., in the Downtowndirection), a line number for each train, a frequency of departure ofeach train, and a countdown to the next scheduled train's departure.

In the illustrated example, the term that is used (e.g., by thepassengers of this particular geographical area in which the subwaystation located) to refer to southbound transit is “Downtown.”Therefore, the map application has identified and displayed Downtown asa trip heading for the subway trains that travel in the southbounddirection from the subway station (i.e., towards the Downtowngeographical region). Under the trip heading, the map application listssubway trains of the lines that are scheduled to depart from the subwaystation next. That is, the map application of some embodiments displaysa list of trains of different lines that will leave the subway stationduring a certain time period from the current time (e.g., the subwaytrains that leave the station in the next 15 minutes). In the exampleshown in stage 520, two different subway trains of the lines 27 and 42will leave the station towards Downtown in the next 12 minutes from thecurrent time of the device (i.e., 1:20 pm). Both of these subway lineshave trains that depart towards Downtown every 15 minutes. The nextscheduled departure for the subway line 27 will be in 7 minutes and thenext scheduled departure for the subway line 42 will be in 12 minutes.

While the examples shown in this figure involve subway stations andsubway trains, one of ordinary skill would realize that the examples areequally applicable to other types of transit stations and other types oftransit vehicles (e.g., from different transit systems) as well. Forinstance, the map application of some embodiments provides a bus stopplacecard that provides the schedule for the buses that stop at the busstop. Similarly, some embodiments provide ferry terminal placecards andrail placecards for ferries and light rails, respectively, with eachplacecard providing different departure schedule for the respectivetransit vehicles.

The illustrated example shows a transit station placecard for a subwaystation in which all the subway trains of different lines are scheduledto depart from the station in short time intervals (e.g., every 15minutes or less). As such, all the departure schedules are displayed inthe frequency formats. As described above, the map application of someembodiments also provides transit station placecards that displaydeparture schedules for low frequency transit vehicles (e.g., transitvehicles that depart from the transit station at longer time intervalssuch as every 30 minutes or more). The map application of some suchembodiments displays the departure schedule differently in such transitstation placecards.

As an example, when a user selects a bus stop representation that isdisplayed on a map presentation of a geographical area provided by themap application, the application provides a bus stop placecard for theselected bus stop. The placecard may then show a departure schedule fortwo different bus lines from the selected bus stop. The first bus linemay include buses that depart from the bus stop with a frequency ofevery 12 minutes. The second bus line may include buses that depart fromthe bus stop with a frequency of every 30 minutes.

The map application of some embodiments displays, in the placecard, thefirst bus line schedule the same way as depicted in stage four of thefigure. That is, the map application displays a trip heading for theline, the line number, and a frequency of departure that states “every12 minutes.” For the second line, however, the map application of someembodiments displays the format of departures differently. For example,in some embodiments, the map application displays the trip heading, theline number under the trip heading, and a set of one or more busrepresentations (e.g., bus logo), with a time of departure in front ofeach bus representation. The number of bus representations in the setvaries in different embodiments. Some embodiments display only the nextbus and its time of departure from the bus stop, while other embodimentsdisplay a certain number of next scheduled departures.

The above-described example illustrated a transit placecard for a subwaystation. In some embodiments, a user may select a transit hubrepresentation on a displayed map presentation. A transit hub in someembodiments is a large transportation facility that includes differenttypes of transit stations (e.g., train station, bus stop, subwaystation, etc.) for different transit vehicles (e.g., light rail trains,buses, subway trains, etc.). Some such embodiments, upon selection ofthe transit hub representation, provide a transit hub placecard with ascrollable display area that includes the departure schedules of all thedifferent types of transit vehicles from the different types of transitstations. The user may then scroll through the different transit linesfor different types of transit vehicles to view the desired transitstation and the departure schedules of the transit vehicles from thedesired transit station.

FIG. 6 illustrates an example of a transit hub placecard that providestransit schedules for different types of transit vehicles and transitlines departing from the transit hub. Specifically, this figure shows,through three operational stages 605-615 of the map application UI, thetransit hub placecard and user interaction with the placecard to viewmore information about the different transit lines' departure schedulefrom the transit hub.

The first stage 605 illustrates that the map application displays, inthe transit placecard display area 530, general information about atransit hub as well as the departure schedule of different transitvehicles (i.e., rail trains) of different lines. The placecard displayarea can be displayed for example in response to a selection of thetransit hub representation on a map presentation similar to the exampleshown in FIG. 5. Although in the illustrated example, the generalinformation about the transit hub only includes the name and address ofthe hub, some embodiments provide a variety of information about thetransit hub in the transit station placecard. For instance, the mapapplication of some embodiments provides information such as directionsto and/or from the station, images of the station (e.g., from bothinside and outside the station), the reviews gathered by informationaggregation entities (e.g., Yelp, Facebook, Twitter, etc.) about thetransit station, etc.

The first stage also shows the departure schedule for all trains thatleave the hub in the Uptown direction. More specifically, this stageshows a trip heading 620 for all the trains that travel north (i.e., inthe Uptown direction), a line number 625 for each train, and thedeparture times 630 of each train of each line. Similar to the lastexample, in the illustrated example, the term that is used (e.g., by thepassengers and transportation system of this particular geographicalarea in which the subway station located) for the north is “Uptown.”Hence the map application has identified and displayed Uptown as aheader for the trains that travel northbound from the subway station.Under the header, the map application lists the different train linesthat are scheduled to depart from the hub in the specified direction. Inthe shown example of stage 605, two different train lines E and D willleave the station in the Uptown direction.

Unlike the previous example though, the departure schedule of the trainlines are not shown in frequency format. This is because these trainlines are categorized as low frequency transit lines and as such theirdeparture times are displayed in absolute times. That is, for each trainline, the map application displays the time at which the next availabletrain of the line leaves the station. In some embodiments, for lowfrequency transit vehicles, the map application displays the time ofdeparture of a next certain number of transit vehicles.

In the illustrated example, for each line, the map application shows thenext two departure times. One of ordinary skill in the art would realizethat different embodiments may show different number of departures foreach line (e.g., the next three departures, the next four departures,etc.). The second stage 610 shows that the user is scrolling up theinformation displayed in the transit station placecard in order to viewother transit information provided by the placecard. In the illustratedexample, the current time shown on the device is 3:47 pm and thereforethe map application displays the next available departure time for theline E at 5:00 pm and after that there is no other train departing inDowntown direction until 6:00 pm. Similarly, the next availabledeparture time for the train line D is at 5:30 pm and after that thereis no other train departing in Downtown direction for this line until7:15 pm.

The third stage 515 shows the transit hub placecard displayingadditional departure information after scrolling the information up. Thedisplay screen 530 now displays the Downtown departure schedule underthe trip heading 635 for the train lines that depart towards Downtown(the local directional term for trains that travel southbound), theEasttown departure schedule under the trip heading 640 for the subwaylines that depart towards Easttown (the local directional term for Eastin this locality), and the Westtown departure schedule under the tripheading 645 for the bus lines that depart towards Westtown (the localdirectional term for west in the locality).

In the illustrated example, the subway trains of the lines 55 and 66 arelisted under the trip header Easttown which shows that these lines arescheduled to depart from the subway station every 5 minutes. This isbecause these subway lines are categorized by the map application (or amapping service that provides these information to the mappingapplication) as high frequency lines. The next scheduled departure forthe subway line 55 will be in 2 minutes while the next scheduleddeparture for the subway line 66 will be in 4 minutes. The third stage615 also shows that the buses of the lines 88 and 99 are listed underthe trip header Westtown which shows that these bus lines depart in thewest direction from this transit hub. However, as shown, the bus line 88is categorized as a high frequency bus line and as such the departureschedule for this line is displayed in frequency format in theplacecard, while the bus line 99 is categorized as a low frequency busline and as such the departure schedule for this line is displayed inabsolute time format (i.e., the time at which the next bus/buses of theline leave the transit hub).

III. Computing Departure Frequencies

As described above, the mapping service of some embodiments calculatesthe frequency of departures of high frequency transit vehicles of atransit line and then displays the calculated frequency. In order tocalculate the frequency of departures, the mapping service of someembodiments uses a novel method that receives a transit line's departureschedule (e.g., a departure timetable of the transit line) for aparticular route of the line and produces frequencies of departure ofthe line at each station along the particular route for any given timeand day. The received departure schedule of the route in someembodiments includes the departure times of the transit vehicles of theline at each transit station of the particular route during a particulartime period (e.g., a day, a week, a month, etc.).

The method first generates a window group for each departure time of theline at a particular station. In some embodiments each window groupincludes a sequence of departure times that starts with thecorresponding departure time at the station and continues with thedeparture times that are after the corresponding departure time, up to areasonable time bound into the future. The time bound in someembodiments can be set to include at least L departures times (e.g., 4departure times) and at most H departure times (e.g., 10 departuretimes), such that the last departure time is no more than T hours (e.g.,2 hours) into the future with respect to the start time.

For example, when the departure times for the bus line X at the bus stopY are “4:49, 5:04, 5:19, 5:34, 6:04, 6:19, 6:34, 6:49, 7:04, 7:19,” thewindow group for the departure time 4:49 at the station includes thedeparture times “4:49, 5:04, 5:19, 5:34, 6:04, 6:19, 6:34,” which isbetween four and ten departure times and at the same time the latesttime in the group is not more than two hours from the start time.Similarly, the window group for the departure time 5:04 at the stationincludes the departure times “5:04, 5:19, 5:34, 6:04, 6:19, 6:34, 6:49,7:04,” and the window group for departure time 5:19 would include “5:19,5:34, 6:04, 6:19, 6:34, 6:49, 7:04, 7:19,” and so on.

The method of some embodiments does not generate a window group when nosuch contiguous subsequence is feasible (i.e., the subsequence ofdeparture times). In some embodiments the subsequence is not feasiblewhen the departure schedule data is not available or the departure timesat the station are drastically different (e.g., there are two departuresin the morning and three departures in the evening). In some otherembodiments, the method generates an empty window group when no suchcontiguous subsequence is feasible. Each generated window group (i.e.,for each associated departure time at the station) is then processedindependently by the method of some embodiments.

The method processes each window group by approximating the sequence ineach window group using a single number that expresses the gaps in thedeparture sequence (i.e., the intervals between each consecutive pair ofdepartures), or a pair of numbers that expresses a range of gaps in thedeparture sequence. The size of the expression generated by the methodof some embodiments is independent of the departure sequence size.Therefore the resulting expression succinctly expresses the sequence.

The method of some embodiments tries to express the sequence of gaps(intervals between departures) with respect to a specification thatincludes several thresholds that are used to determine whether thecollection of successive gaps in the departure times can be expressed by(1) a single exact number, (2) a single approximate number, or (3) apair of numbers that describes the range of gaps between successivedeparture times. FIG. 7 conceptually illustrates a process 700 that someembodiments perform to determine how to express (present) the departureschedule of a high frequency transit line. Specifically, the process 700determines whether to express the departure intervals with an exactnumber, an approximate number, or a range of numbers. It should beunderstood that the process 700 is only one such possible process, andthat different embodiments may use variations on this process. Forinstance, some embodiments do not differentiate between expressing thedeparture intervals as an exact number or an approximate number, andinstead only determine whether to express these intervals as a singlenumber or a range of numbers.

In some embodiments a mapping service that runs on one or more dedicatedservers performs the process and stores the results to be sent to themap application or returns the results in real time (i.e., upon request)to the map application. In some other embodiments, the process isperformed by a map application that executes on a device. In someembodiments, the process is performed by a mapping service that runs onone or more servers and provides the transit data (e.g., routing,navigation, incidents, direction labeling, etc.) to the map application.In some other embodiments, the process is performed by one or moreservers that are designated specifically for computing departurefrequencies. In some embodiments, the server pre-computes the departurefrequencies of different transit lines and upon startup loads thepre-computed frequencies into memory (e.g., volatile memory, etc.) andorganizes the frequencies in the memory.

In some such embodiments a map application sends a request for thedeparture schedule of a transit line to the server. The request for thedeparture schedule in some embodiments specifies the transit line, thetransit station from which the transit vehicles of the transit linedepart, the particular time for which the schedule is needed, and thetrip heading of the line at the transit station. Upon receipt of such arequest, the server retrieves the related contiguous group offrequencies of departures from the memory and sends the retrieved groupback to the requesting map application. In some embodiments, the serveralso sends back a particular number of frequencies of departurescorresponding to near future times of the requested time to therequesting map application.

The process 700 is described by reference to FIG. 8, which provides anexample for calculating a range of departures as the departure scheduleof a transit line at a particular station. The process 700 begins byreceiving (at 705) a window group that includes a sequence of departuretimes of transit vehicles of a transit line that head in the samedirection from a particular transit station during a certain period oftime. In FIG. 8 the window group is shown as a sequence of departuretimes “5:10, 5:20, 5:30, 5:41, 5:51, and 6:00.” These departure timescorrespond for example to departure times of a subway line at aparticular subway station within one hour.

In some embodiments the window group is generated from a departureschedule of a line (e.g., departure timetable) for a particular route asdiscussed above. Some embodiments receive the schedule for the line,among a collection of departure schedules for a collection of transitlines, from one or more transit service data providers. Some suchembodiments store the received transit data and update the stored dataperiodically. Some other embodiments update the stored transit data whenthe updates are available by the transit service data providers.

The process 700 then calculates (at 710) the gaps between the successivedeparture times of the transit line in the window group. In other words,the process calculates a sequence of differences between successivedeparture times in the window group, Δ={δ′_(j)}, where eachδ′_(j)=t_(j+1)−t_(j). As illustrated in FIG. 8, the sequence of gaps forthe window group shown in this figure is “10, 10, 11, 10, and 9.” Aftercalculating the gaps, the process of some embodiments sorts thecalculated sequence of the gaps. Therefore, in this example, the processgenerates a sorted sequence of the gaps such as Δ=

9, 10, 10, 10, 11

.

The process then determines (at 715) whether a single value accuratelyexpresses the calculated sequence corresponding to the departure timesin the window group. That is, the process determines whether a singlenumber within a small threshold expresses the sequence. The process ofsome embodiments makes such a determination with respect to an inputparameter, σ_(e). The process examines the variance of the set Δ anddetermines whether the variance is at most σ_(e) ². When the variance isless or equal to σ_(e) ², the process determines that the mean departurefrequency (μ(Δ)) expresses the gaps exactly and returns (at 720) thevariance as a single value that represents the departure frequency. Thatis, when the process determines that the departure gaps are within asmall threshold deviation of a mean time gap, the process returns themean time gap as the departure frequency of the transit line.

In the example shown in FIG. 8, the variance is 0.4 minutes. That is, aslong as the threshold σ_(e) is greater than 0.4, the process returns themean departure gap of “10” as the departure frequency for this windowgroup. That is, the departure frequency of this subway line is “every 10minutes.” One of ordinary skill in the art would realize that thenumbers given in this example (and other examples) are only exemplaryand the real numbers are in fact different. For instance the thresholdthat is used by the process could be significantly smaller than 0.4 insome embodiments. While this example uses a fixed threshold, someembodiments vary the threshold with the mean of the departure gaps.Thus, larger gaps (e.g., every 30 or 60 minutes) will have largerallowable variances, to comport with common thinking. For instance,departure gaps of 40 to 50 minutes might be commonly expressed as “every45 minutes”, whereas departure gaps of 5 to 15 minutes would not becommonly expressed as “every 10 minutes”. In addition, some embodimentsmay vary the threshold based on other variables, such as the geographicarea (e.g., different threshold variances may be allowed based on howtightly the transit lines tend to stick to their schedules).

In other embodiments, the process makes the determination as to whetherto express the sequence of departure times with respect to two inputparameters, ε₁ and λ. The process, in this case, approximates thedistribution of the set Δ with a univariate Gaussian, N(μ, σ), and thendetermines whether ∫_((1−ϵ))μ^((1+ϵ)μ)N(μ, σ)dx>λ. The input parametersare defined such that 0≤ε₁ and λ≤1. Some embodiments, as an example, useε₁=0.1 and λ=0.7.

On the other hand, when the process is unable to express the sequence ofgaps exactly, the process determines (at 725) whether one of a set ofranges can express the calculated sequence. Specifically, the processdetermines whether the sequence can be expressed by a pair of deltasfrom amongst a canonical set of ranges, C. In some embodiments, C is ahand-curated collection of univariate pairs of Gaussian distributionsthat is defined by C={(N_(i) ^(l)(μ_(i) ^(l), σ_(i) ^(l)), N_(i)^(h)(μ_(i) ^(h),σ_(i) ^(h)))}_(i) ^(K)=1, with the first Gaussian in thepair expressing the low range, and the second Gaussian expressing thehigh range. The hand-curated collection of pairs of some embodimentsincludes a set of predefined pairs (e.g., “2-3, 2-5, 5-7, 5-10, 10-15,10-20, 15-20, . . . ”) that could be used as candidate pairs forcomputing the range. In addition, corresponding to each i from 1 to K,there is also a pair of display frequencies, which are the actual lowand high frequencies for display purposes. Thus, for example, the set ofpairs of Gaussian distributions might include the pair (4, 11) as themeans corresponding to the Gaussian pair, but with a corresponding pairof display frequencies (5, 10), such that the displayed frequency wouldbe “every 5 to 10 minutes” rather than “every 4 to 11 minutes”.

Some embodiments distinguish between the case in which the distributionof the departure gaps can be approximated well by a pair ofwell-separated univariate Gaussians in the set of canonical Gaussianpairs, and the case where the minimum and maximum of the distributioncan be approximated well by a pair of means from among the set ofcanonical Gaussian pairs. In some embodiments, the process firstattempts to find a Gaussian pair, and only if this fails, then attemptsto find a best pair of means that approximate the minimum and maximum ofthe intervals.

In order to attempt to find a pair of well-separated univariateGaussians in the set of canonical pairs, the process of some embodimentsdefines a set of feasible solutions, and then optimizes the defined setof solutions. To do so, the process tries all possible bi-partitions ofthe sorted sequence, Δ={δ′_(j)}. The second window group of FIG. 8 is asequence of departure times “5:10, 5:14, 5:20, 5:29, 5:39, and 5:51.”Therefore, the sequence of gaps for this window group in the figure is“4, 6, 9, 10, and 12.” The possible bi-partitions of the sequence asshown in FIG. 8 are (4; 6, 9, 10, 12), (4, 6; 9, 10, 12), (4, 6, 9; 10,12), and (4, 6, 9, 10; 12).

One of ordinary skill in the art would realize that the departure timesgiven in this example are only exemplary and the real departure timescould be in fact different. In other words, the departure times in theexample are selected in such a way to render a sorted sequence of gapsfor simplicity of description and a sequence of real departure times mayrender an unsorted list of gaps between the successive departures. Someembodiments, as described above, sort the sequence of gaps (e.g., fromthe lowest number to the highest) after calculating the gaps in thesequence of departures.

Each bi-partition, in some embodiments, includes a set of small deltasand large deltas. The process interprets the associated deltas as aGaussian. Thus, for each bi-partition, the process generates a pair ofGaussians, one of which describes the set of small deltas, and the otherone describes the set of large deltas. For each such choice, the processfinds a set of feasible Gaussian pairs from amongst the canonical set ofGaussian pairs, C. For the pair of Gaussians corresponding to thepartition, (N_(i) ^(l), N_(i) ^(h)), and a candidate canonical Gaussianpair, (N_(c) ^(l), N_(c) ^(h)), the process determines that thecandidate is feasible if N_(i) ^(l) is “well inside” N_(c) ^(l) andN_(i) ^(h) is “well inside” N_(c) ^(h). This notion of “well-inside” isexpressed by a parameter.

For the set of feasible solutions thus defined, the process picks afeasible canonical candidate whose average statistical distance is thesmallest, over the low and the high deltas. In the above example, theprocess would determine that the bi-partition (4, 6; 9, 10, 12) couldfit well inside the candidate range of 5-10 minutes and therefore theprocess returns the departure range as being between 5-10 minutes.Specifically, the first group (4, 6) has a mean of 5 and a variance ofσ² of 1, while the second group (9, 10, 12) has a mean of 10.3 and avariance of σ² of 1.6. Again, the numbers are exemplary and the realnumber and values that are used in these distributions and formulas maybe significantly different than the number and values illustrated in theabove and below examples.

The process of some embodiments uses the standard concept of HellingerDistance between a pair of Gaussians. One of ordinary skill in the artwould realize, however, that other appropriate forms of statisticaldistances between a pair of Gaussians could be equally applicable.Algorithm 1 below describes this accurately. Some notations are abusedto let Δ also denote the sorted sequence corresponding to the set Δ,that is Δ[i]≤Δ[j], i<j, for the sake of notational convenience. Also, inAlgorithm 1, Δ[i . . . j],1≤i≤j≤L denotes the consecutive subsequence ofΔ between i and j.

Algorithm 1: FindBestGaussianPair(Δ[1 . . . L], C) closest ← ∞ for i ←1:L do  N_(i) ^(l) ← (μ_(i)(Δ[1...i]),σ_(i)(Δ[1...i]))  N_(i) ^(h)←(μ_(i)(Δ[i+1...L]),σ_(i)(Δ[i+1...L]))  F_(i) ← {(N_(c) ^(l), N_(c)^(h)) : d_(l)(N_(i) ^(l), N_(c) ^(l)) < ε₂, d_(l)(N_(i) ^(h), N_(c)^(h)) < ε₂, (N_(c) ^(l), N_(c) ^(h)) ∈ C}  (N_(c) ^(l), N_(c) ^(h)) ←argmin_(c∈F) _(i) {d₂(N_(i) ^(l), N_(c) ^(l)) + d₂(N_(i) ^(h), N_(c)^(h))}  if d₂(N_(i) ^(l), N_(c) ^(l)) + d₂(N_(i) ^(h), N_(c) ^(h)) <closest then   closest ← d₂(N_(i) ^(l), N_(c) ^(l)) + d₂(N_(i) ^(h),N_(c) ^(h))   (N _(O) ^(l) , N _(O) ^(h) ) ← ( N _(c) ^(l) , N _(c) ^(h)) if closest < ∞ then  return (N_(O) ^(l) ,N_(O) ^(h)) return ∅

Some embodiments use 0.05 for the value of ε₂ in the above algorithm. Inthe above Algorithm 1, d2(.,.) is the Hellinger Distance between twoGaussians. In Algorithm 2 below, d1(.,.) is defined.

Algorithm 2: d₁(N_(a), N_(b))   l_(a) ← μ_(a) − σ_(a) h_(a) ← μ_(a) +σ_(a) l_(b) ← μ_(b) − σ_(b) h_(b) ← μ_(b) + σ_(b) if (l_(a), h_(a)) and(l_(b), h_(b)) do not overlap then  return 1 S ←(min{h_(a),h_(b)}−max{l_(a),l_(b)})/ (h_(a)−l_(a)) return 1−S

In the above Algorithm 2, in order to prevent the result of h_(a)−l_(a)from being zero and hence S being undefined, some embodiments, subtracta small value (ε′) from l_(a) and add the same small value to h_(a) atthe beginning of the algorithm. The same small value (ε′) is also addedto and subtracted from h_(b) and l_(b), respectively.

When the distribution cannot be approximated using a pair of Gaussiansfrom the canonical set, the process attempts to find a Gaussian pairamong the canonical set such that the pair of means “fits” the minimumand maximum values of the distribution well. Basically, this operationcompares the minimum and maximum values with the low and high means fromamongst the set of canonical Gaussian pairs. For a fixed pair ofGaussians, (N_(c) ^(l), N_(c) ^(h)), from the set of canonical Gaussianpairs C, the low and high means are denoted by μ_(c) ^((l)), μ_(c)^((h)) respectively. The process denotes a pair of means (μ_(c) ^((l)),μ_(c) ^((h))) as feasible for the minimum and maximum values of thedistribution (denoted as (min, max)) if and only if min ∈(1±ϵ₃)μ_(c)^((l)) and max ϵ(1±ε₃)μ_(c) ^((h)). Some embodiments use 0.2 for thevalue of ε1. Using the value F to denote the subset of such qualifyingpairs for (min, max), the process of some embodiments selects a pair forwhich the average distance to (min, max) is the smallest. This processis described by the following Algorithm 3:

Algorithm 3: FindBestMeanPairforMinMax(Δ[1 . . . L], C) (min, max) ←(min(Δ), max(Δ)

 ← {(μ_(c) ^((l)),μ_(c) ^((h))) : min ∈ (1 ± ε₃)μ(N_(c) ^(l)), max ∈ (1± ε₃)μ(N_(c) ^(h)),(N_(c) ^(l), N_(c) ^(h)) ∈ C } (α, β) ←

 {|μ_(c) ^((l)) − min| + |μ_(c) ^((h)) − max|} return (α, β)

When the process determines that one of the pair of deltas (i.e., one ofthe pairs in the set C) as described above (either a pair of Gaussians,or a pair of means) expresses the gaps, the process returns (at 730) thepair as the range of departure frequency. On the other hand, when theprocess is unable to express the sequence of gaps using one of the pairsin the set C, the process determines (at 735) whether a single valueapproximately expresses the gaps, Δ={δ′_(j)} corresponding to thedeparture times in the window group. That is, the process determineswhether a single number within a large threshold expresses the sequence.The process of some embodiments makes such a determination with respectto an input parameter, σ_(a), which is greater than the input parameterσ_(e) (σ_(a)>σ_(e)). The process of some such embodiments examines thevariance of Δ and determines whether the variance is at most σ_(a) ².When the process determines that the variance is less or equal to σ_(a)², the process realizes that the mean departure frequency (μ(Δ))expresses the gaps approximately and returns the variance (at 740) as asingle value that represents the approximate departure frequency. Insome embodiments, when the process determines that the variance does notexpress the gap approximately, the process returns (at 750) a variable(e.g., a zero) that shows no frequency can be determined for thedepartures. Other embodiments do not differentiate between an exactsingle value and an approximate single value.

The map application of some embodiment deploys this process or a processsimilar to this to calculate the frequency of departures of a highfrequency transit line upon a request. For instance when the mapapplication receives a request for a placecard of a transit station, itcalculates the departure frequencies of the different transit linesdeparting from the transit station and provides the departurefrequencies in the placecard, as discussed above. Or when the mapapplication receives a request for a navigation presentation, theapplication calculates and displays the departure frequencies in thecorresponding navigation banners. In some other embodiments, when a mapapplication receives a request for a departure schedule (e.g., to bedisplayed in a placecard, a navigation banner, etc.), the applicationsends a request to one or more servers that are dedicated for frequencyschedules and calculations and receives the requested information backfrom those servers.

The servers of some such embodiments calculate the departure frequencieswhen they receive a request from the map application. Alternatively, orconjunctively, the dedicated servers pre-calculate the frequencyschedules (e.g., after receiving a new or updated set of departuretimetables) and store the calculated frequencies in one or more datastorages for later use (e.g., to be displayed in different userinterfaces of the map application). Upon receiving the request fordeparture schedules from a map application, these servers retrieve therelated stored schedules and send them to the requesting mapapplication.

FIG. 9 conceptually illustrates a frequency generator module that someembodiments use for determining in which format the frequency ofdepartures should be displayed for a particular transit line leaving aparticular transit station at a particular time of day. Morespecifically, the frequency generator module determines which one of theabove three expressions can be applied to the sequence of the departuregaps. As shown, the frequency generator module of some embodimentsincludes several other modules which are a window group generator module920, an exact singleton generator module 930, a range generator module940, and an approximate singleton generator module 950.

The frequency generator module 910 receives a departure timetable 960 asan input. The timetable in some embodiments is one of a collection oftimetables that the module receives from one or more transit dataproviders. As shown in the figure, the timetable 960 includes a set ofcolumns and a set of rows. The columns of the timetable correspond tothe transit stations at which the transit vehicles of the transit linestops. The rows of the timetable correspond to a sequence of departuretimes of the transit vehicles of the transit line at each transitstation. For example the first row shows the departure times of thefirst bus of the line at each bus stop, the second row shows thedeparture times of the second bus of the line at the bus stops, and soon.

The window group generator module of the frequency generator modulereceives the timetable and as described above, iteratively generates awindow group for each departure time of a column of the timetable (e.g.,the highlighted column for the bus stop of Main Street). For eachtransit station column then, the frequency generator module outputs acolumn with multiple cells that each includes a departure frequency foreach corresponding cell of the transit station column. Each cell of theoutput column represents the frequency of departures for the nexttransit vehicle of the line and can be in one of the threeabove-described formats (i.e., exact time, approximate time, or a timerange).

As shown in the figure, the output column 970 which corresponds to thedeparture frequency of the highlighted column of the timetable 960 (forthe Main Street stop) has several cells. The two first cells of thecolumn show that the departure frequencies for the first and secondbuses of the line at Main station are every 5 minutes (i.e., the timeinterval between each pair of departures of the line at this station is5 minutes). The third cell of the column shows that the departurefrequency for the third bus of the line at Main station is between 5-7minutes while the fourth cell shows that the departure frequency for thefourth bus is between 10-15 minutes. Finally, the fifth cell of thecolumn shows that the departure frequency for the fifth bus of the lineat Main station is between approximately about 6 minutes.

In order to produce this output, the frequency generator module of someembodiments, for each generated window group that corresponds to adeparture time of the line, computes the differences between successivecells of the window group (δ′_(j)=t_(j+1)−t_(j)) and generates asequence of time gaps ({δ′_(j)}). The sequence is then fed into theexact singleton generator module 930 along with an input parameterσ_(e). The exact singleton generator, as described above, examines thevariance of A in the sequence and determines whether the variance is atmost σ_(e) ². When the module determines that the variance is less orequal to σ_(e) ², it renders the variance as the exact frequency ofdepartures.

When such determination is not feasible, the next module, which is therange generator module 950, starts to determine whether the generatedsequence of gaps can be expressed by a pair of deltas from amongst acanonical set of ranges, C. The module receives the sequence ({δ′_(j)})along with a canonical set C ({(N_(i) ^(l)(μ^(l) _(i), σ_(i) ^(l)),N_(i) ^(h)(μ^(h) _(i), σ_(i) ^(h))}^(K) _(i=1)) and parameters ε₂ and ε₃(e.g., 0.05 and 0.2). As described above, the range generator modulethen tries to separate the sequence into two Gaussians that best fit anelement of the canonical set C.

When such determination is not feasible either, the next module, whichis the approximate singleton generator module 950, starts to determinewhether a single number can approximate the generated sequence of gaps{δ′_(j)} with respect to an input parameter σ_(a) that the modulereceives. In some embodiments the input parameter σ_(a) is greater thanthe input parameter σ_(e). The approximate singleton generator moduleexamines the variance of Δ in the sequence and determines whether thevariance is at most σ_(a) ². When the module determines that thevariance is less or equal to σ_(a) ², it returns the variance as asingleton that approximately represents the departure frequency. Inother embodiments, the exact and approximate singleton generators are asingle module that uses the parameters ε₁ and λ as inputs, as describedabove.

All the frequency schedules that are described thus far are schedule (ordeparture) frequencies. In other words, the above-described frequenciesare departure frequencies of the transit vehicles of a particulartransit line that depart from a particular transit station. The mapapplication of some embodiment also displays a transit frequency orroute frequency for a selected transit route that includes multiple legsfrom a starting location to a destination. Each leg of a selectedtransit route either uses a different transit vehicle or is a “walk”directive through a navigable pedestrian network.

The map application of some embodiments can also calculate and providean overall transit frequency (or request the calculation of such from amapping service running on one or more dedicated servers) and displaythe calculate frequency when all the legs of the transit route areserviced by high frequency transit vehicles. In some other embodiments,the map application calculates (or requests the calculation) anddisplays the transit frequency for a transit route even when the transitvehicles of the different legs of the transit route are a combination ofhigh frequency and low frequency transit vehicles.

FIG. 10 conceptually illustrates a process 1000 that some embodimentsperform to calculate the overall transit frequency for a selectedtransit route. Specifically, the process 1000 generates a window groupfor the transit route that can be used as an input for the processdescribed above by reference to FIG. 7 in order to generate the transitroute's frequency. The computed window group for the transit routeincludes a sequence of departure times from the starting location in thefirst leg. Each departure time in the sequence is the latest departuretime from the starting location in order to make a temporally feasibleand independent transit trip to the destination during the time periodused to compute the window group.

In some embodiments a mapping service that runs on one or more dedicatedservers performs the process and stores the results to be sent to themap application or returns the results in real time (i.e., upon arequest) to the map application. In some other embodiments, the processis performed by a map application that executes on a device. In someembodiments because of the high temporal variability and combinatorialcomplexity involved in pre-computing transit routes' schedules(frequencies), the map application and/or dedicated servers compute thetransit frequency on demand only. That is, a mapping service, or one ormore dedicated servers that are designated for computing departurefrequencies, compute the overall transit frequency for a transit routeonly when they receive a request for such from a map application.

The process 1000 will be described by reference to FIG. 11, whichprovides an example for calculating a sequence of departures (i.e., awindow group) that includes the departure times from the currentposition of the device. FIG. 11 illustrates a transit route 1105 thatincludes four transit legs 1110-1125. The first transit leg 1110represents a walking route from the starting location of the passengerto the first transit station. The last transit leg 1125 also representsa walking route from the last transit station to the desireddestination. The second and third legs 1115 and 1120 use two differenttransit vehicles. The number of minutes next to each leg (on the lefthand side of the figure) is the expected length of time to make thecorresponding trip. For instance the trip time for the first walking legis five minutes while the trip time for the last walking leg is sevenminutes.

Some embodiments treats the walking routes as transit routes that departevery minute, thus, are unconstrained. Some such embodiments set aside aone-minute transition time at each transit station that acts as abuffer, allowing the passenger to make a feasible transition to the nextleg of the transit route. These embodiments charge this transition costto the transit duration of the previous leg in the transit route.

The process 1000 begins by receiving (at 1005) the departure scheduleand transit time of each leg of a selected transit route. In the exampleof FIG. 11 the process receives the departure schedules 1130-1145 whichare sequences of numbers that represent the departure times from thesource of the corresponding legs 1110-1125. As stated above, thepedestrian legs are treated as transit routes that depart every minute,hence the departure schedules 1130 and 1145 include departure times thatoccur every minute at the source of the corresponding pedestrian leg.Additionally, the numbers in the last sequence 1150 represent thearrival times at the destination using the last walking leg.

The process 1000 then stores (at 1010) the departure times of the firstleg (i.e., schedule 1130) as the possible departure times of the route.That is the departure times of the first leg are initially stored by theprocess as a potential sequence of departure times that could be thelatest departure times from the starting location in order to make atemporally feasible transit trip to the destination. In the illustratedexample, therefore, the sequence 1130 is stored as the potentialdeparture times.

Next, the process selects (at 1015) the first leg as the current leg toprocess. The process then identifies (at 1020), for each feasibledeparture of the next leg, the latest departure time of the current legthat would allow the passenger to arrive at the next leg by thatdeparture time. In other words determines what departure time in thecurrent leg would be the latest time that the passenger can depart fromthe source of the current leg in order to catch a particular one of thedeparture times of the next leg. Therefore, in the example of FIG. 11,the process identifies departure time minute 5 in the first leg as thelatest time in order to catch the departure time minute 10 in the secondleg. This is because the passenger has to walk for 5 minutes (i.e., thetransit time for the first leg) in order to get to the starting transitstation of the second leg.

Similarly, the process identifies departure time minute 7 in the firstleg as the latest time in order to catch the departure time minute 12 inthe second leg, departure time minute 15 in the first leg as the latesttime for the departure time minute 20 in the second leg, departure timeminute 17 as the latest time for minute 22, departure time minute 25 asthe latest time for minute 30, departure time minute 27 as the latesttime for minute 32, and finally the departure time minute 28 as thelatest time to catch the departure time minute 33 in the second leg.

After identifying the latest departure time in the current leg for eachfeasible departure time in the next leg, the process 1000 stores (at1030), for each identified departure time, a path (link) from theidentified departure time in the current leg to its correspondingfeasible departure time in the next leg. In the example of FIG. 11, theprocess stores a path (link) from minute 5 in the first leg (which isthe current leg when processing the first leg), to its corresponddeparture time in the second leg which is minute 10. Similarly, theprocess stores paths (links) from minute 7 of the first leg to minute 12of the second leg, from minute 15 to minute 20, from minute 17 to minute22, from minute 25 to minute 30, from minute 27 to minute 32, andfinally from minute 28 to minute 33.

The process then determines (at 1040) whether the next leg forprocessing is the last leg of the transit trip. If the processdetermines that next leg for processing is not the last leg of thetransit route, the process selects (at 1045) the next leg as the currentleg for processing and returns to 1020 to identify the latest departuretimes for that leg. In the example of FIG. 11, the process determinesthat there are more legs to process and therefore selects the second legas the current leg to process. The process then identifies minute 10 asthe latest departure time in the second leg to catch the departure timeminute 21 in the third leg.

This is because the trip time of the second leg is 10 minutes and thusthe first departure time in the second leg (minute 10) can catch thedeparture time minute 21 in the third leg. Similarly, the processidentifies departure time minute 12 in the second leg as the latest timeto catch the departure time minute 25 in the second leg, departure timeminute 20 as the latest time for minute 30, departure time minute 30 asthe latest time for minute 40, and finally the departure time minute 33as the latest time to catch the departure time minute 50 in the secondleg. The process then stores a path from each identified departure ofthe second leg to its corresponding departure time in the third leg.

That is, the process stores a path between minute 10 of the second legand minute 21 of the third leg, between minute 12 of the second leg andminute 25 in the third leg, between minute 20 of the second leg andminute 30 of the third leg, between minute 30 of the second leg andminute 40 of the third leg, and finally between minute 33 of the secondleg and minute 50 of the third leg. The process iteratively performsthese steps until the last leg of the transit route is also processed.After processing the last leg (i.e., the second to last leg in thetransit route), the process has stored, for each identified departuretime of the first leg, a path that starts from the first leg and eitherreaches a departure time in the last leg or ends somewhere in between.That is, after storing all the paths (links), there might be some linksthat do not connect any identified departure times of the first leg toany feasible departure time of the last leg.

When the process 1000 determines (at 1040) that the it has reached thelast leg of the transit route, the process removes (at 1045) thedeparture times of the first leg that do not have a unique path to afeasible departure time in the last leg. In other words, the processexamines the paths that it has stored (at 1030) for each identifieddeparture time of each leg. If the process can connect the paths fromeach identified departure time in the first leg to make a unique pathfrom the first leg to the last leg, the process keeps that departuretime of the first leg, otherwise the process removes the departure timefrom the list of identified departure times of the first leg.

In the example of FIG. 11, the process starts with the minute 5 of thefirst leg, which was identified as a potential transit departure time.By examining the stored paths, the process realizes that minute 5 of thefirst leg is linked to minute 10 of the second leg, which in turn islinked to minute 21 of the third leg, and minute 21 of the third leg islinked to minute 36 of the last leg. Therefore the process determinesthat there is a direct path (link) between minute 5 of the first leg andminute 36 of the last leg. The same determination is made for minutes 7,15, 27, and 27. However, for minute 17, the process determines thatthere is a link between minute 17 of the first leg and minute 22 of thesecond leg, but the link is disrupted there and there is no more linksto the third leg from the minute 22 of the second leg.

Consequently the process removes departure time minute 17 from the firstleg, hence the link from this departure time to the next leg is shownwith dashed line instead of a solid line. The process also determinesthat there is not a unique link from minute 27 of the first leg to anydeparture time of the last leg and therefore it is removed from thefirst leg as well. As a result, the remaining departure times in thefirst leg, after removal of non-linked departure times in the list ofidentified departure times of the first leg, will be departure times 5,7, 15, 27, and 28 which are shown in the figure as connected to the nextleg with a solid ling.

The process then uses (at 1050) the remaining departure times of thefirst leg (i.e., departure times 5, 7, 15, 27, and 28) as the departuretimes of the transit route. Specifically, the process of someembodiments uses the remaining sequence as a window group for thetransit route and calculates (at 1055) the transit route's departurefrequency based on this window group. The process of some embodimentscalculates the departure frequency by using the window group as an inputfor the process described above by reference to FIG. 7 in order togenerate the transit route's frequency. The process then ends. As statedabove, each departure time in this window group would be the latestdeparture time from the starting location (i.e., the current location ofthe passenger) in order to make a transit trip to the destination duringthe time period used to generate the window group.

Some embodiments perform variations of the process 1000. The specificoperations of the process 1000 may not be performed in the exact ordershown and described. Additionally, the specific operations may not beperformed in one continuous series of operations, and different specificoperations may be performed in different embodiments. For example, insome embodiments, the process returns the generated window group (theremaining transit routes in the sequence) to the map application. Themap application of some such embodiments then displays the sequence tothe user so the user would know when to leave the current location to beable to catch the transit vehicles of a particular transit route. Theuser could also easily determine the time of arrival at the destinationif the user takes a particular transit route that departs at one of theidentified departure times of the first leg.

For example, in the above described FIG. 11, a user by looking at thedeparture sequence would realize that if the user starts his trip atminute 5 (e.g., 5 minutes after the current time), the user would beable to board a transit vehicle at the first transit station at minute10, board a transit vehicle at the second transit station at minute 21,and arrive at the destination at minute 43. Similarly, if the userstarts his trip at minute 28, the user would be able to board a transitvehicle at the first transit station at minute 33, board a transitvehicle at the second transit station at minute 50, and arrive at thedestination at minute 72.

IV. Electronic System

Many of the above-described features and applications are implemented assoftware processes that are specified as a set of instructions recordedon a computer readable storage medium (also referred to as computerreadable medium). When these instructions are executed by one or morecomputational or processing unit(s) (e.g., one or more processors, coresof processors, or other processing units), they cause the processingunit(s) to perform the actions indicated in the instructions. Examplesof computer readable media include, but are not limited to, CD-ROMs,flash drives, random access memory (RAM) chips, hard drives, erasableprogrammable read-only memories (EPROMs), electrically erasableprogrammable read-only memories (EEPROMs), etc. The computer readablemedia does not include carrier waves and electronic signals passingwirelessly or over wired connections.

In this specification, the term “software” is meant to include firmwareresiding in read-only memory or applications stored in magnetic storagewhich can be read into memory for processing by a processor. Also, insome embodiments, multiple software inventions can be implemented assub-parts of a larger program while remaining distinct softwareinventions. In some embodiments, multiple software inventions can alsobe implemented as separate programs. Finally, any combination ofseparate programs that together implement a software invention describedhere is within the scope of the invention. In some embodiments, thesoftware programs, when installed to operate on one or more electronicsystems, define one or more specific machine implementations thatexecute and perform the operations of the software programs.

A. Mobile Device

The applications of some embodiments operate on mobile devices, such assmart phones (e.g., iPhones®) and tablets (e.g., iPads®). FIG. 12illustrates an example of an architecture 1200 of such a mobilecomputing device. As shown, the mobile computing device 1200 includesone or more processing units 1205, a memory interface 1210 and aperipherals interface 1215.

The peripherals interface 1215 is coupled to various sensors andsubsystems, including a camera subsystem 1220, a wired communicationsubsystem(s) 1223, a wireless communication subsystem(s) 1225, an audiosubsystem 1230, an I/O subsystem 1235, etc. The peripherals interface1215 enables communication between the processing units 1205 and variousperipherals. For example, an orientation sensor 1245 (e.g., a gyroscope)and an acceleration sensor 1250 (e.g., an accelerometer) is coupled tothe peripherals interface 1215 to facilitate orientation andacceleration functions.

The camera subsystem 1220 is coupled to one or more optical sensors 1240(e.g., a charged coupled device (CCD) optical sensor, a complementarymetal-oxide-semiconductor (CMOS) optical sensor, etc.). The camerasubsystem 1220 coupled with the optical sensors 1240 facilitates camerafunctions, such as image and/or video data capturing. The wiredcommunication subsystem 1223 and wireless communication subsystem 1225serve to facilitate communication functions.

In some embodiments, the wireless communication subsystem 1225 includesradio frequency receivers and transmitters, and optical receivers andtransmitters (not shown in FIG. 12). These receivers and transmitters ofsome embodiments are implemented to operate over one or morecommunication networks such as a GSM network, a Wi-Fi network, aBluetooth network, etc. The audio subsystem 1230 is coupled to a speakerto output audio (e.g., to output voice navigation instructions).Additionally, the audio subsystem 1230 is coupled to a microphone tofacilitate voice-enabled functions in some embodiments.

The I/O subsystem 1235 involves the transfer between input/outputperipheral devices, such as a display, a touch screen, etc., and thedata bus of the processing units 1205 through the peripherals interface1215. The I/O subsystem 1235 includes a touch-screen controller 1255 andother input controllers 1260 to facilitate the transfer betweeninput/output peripheral devices and the data bus of the processing units1205. As shown, the touch-screen controller 1255 is coupled to a touchscreen 1265. The touch-screen controller 1255 detects contact andmovement on the touch screen 1265 using any of multiple touchsensitivity technologies. The other input controllers 1260 are coupledto other input/control devices, such as one or more buttons. Someembodiments include a near-touch sensitive screen and a correspondingcontroller that can detect near-touch interactions instead of or inaddition to touch interactions.

The memory interface 1210 is coupled to memory 1270. In someembodiments, the memory 1270 includes volatile memory (e.g., high-speedrandom access memory), non-volatile memory (e.g., flash memory), acombination of volatile and non-volatile memory, and/or any other typeof memory. As illustrated in FIG. 12, the memory 1270 stores anoperating system (OS) 1271. The OS 1271 includes instructions forhandling basic system services and for performing hardware dependenttasks. The memory 1270 additionally includes layout rearranginginstructions 1272 in order for the device 1200 to perform the layoutrearranging process of some embodiments. In some embodiments, theseinstructions 1272 may be a subset of the operating system instructions1271, or may be part of the instructions for an application.

The memory 1270 also includes communication instructions 1274 tofacilitate communicating with one or more additional devices (e.g., forpeer-to-peer data sharing, or to connect to a server through theInternet for cloud-based data sharing); graphical user interfaceinstructions 1276 to facilitate graphic user interface processing; imageprocessing instructions 1278 to facilitate image-related processing andfunctions; input processing instructions 1280 to facilitateinput-related (e.g., touch input) processes and functions; audioprocessing instructions 1282 to facilitate audio-related processes andfunctions; and camera instructions 1284 to facilitate camera-relatedprocesses and functions. The instructions described above are merelyexemplary and the memory 1270 includes additional and/or otherinstructions in some embodiments. For instance, the memory for asmartphone may include phone instructions to facilitate phone-relatedprocesses and functions. The above-identified instructions need not beimplemented as separate software programs or modules. Various functionsof the mobile computing device can be implemented in hardware and/or insoftware, including in one or more signal processing and/or applicationspecific integrated circuits.

While the components illustrated in FIG. 12 are shown as separatecomponents, one of ordinary skill in the art will recognize that two ormore components may be integrated into one or more integrated circuits.In addition, two or more components may be coupled together by one ormore communication buses or signal lines. Also, while many of thefunctions have been described as being performed by one component, oneof ordinary skill in the art will realize that the functions describedwith respect to FIG. 12 may be split into two or more integratedcircuits.

B. Computer System

FIG. 13 conceptually illustrates another example of an electronic system1300 with which some embodiments of the invention are implemented. Theelectronic system 1300 may be a computer (e.g., a desktop computer,personal computer, tablet computer, etc.), phone, PDA, or any other sortof electronic or computing device. Such an electronic system includesvarious types of computer readable media and interfaces for variousother types of computer readable media. Electronic system 1300 includesa bus 1305, processing unit(s) 1310, a graphics processing unit (GPU)1315, a system memory 1320, a network 1325, a read-only memory 1330, apermanent storage device 1335, input devices 1340, and output devices1345.

The bus 1305 collectively represents all system, peripheral, and chipsetbuses that communicatively connect the numerous internal devices of theelectronic system 1300. For instance, the bus 1305 communicativelyconnects the processing unit(s) 1310 with the read-only memory 1330, theGPU 1315, the system memory 1320, and the permanent storage device 1335.

From these various memory units, the processing unit(s) 1310 retrievesinstructions to execute and data to process in order to execute theprocesses of the invention. The processing unit(s) may be a singleprocessor or a multi-core processor in different embodiments. Someinstructions are passed to and executed by the GPU 1315. The GPU 1315can offload various computations or complement the image processingprovided by the processing unit(s) 1310. In some embodiments, suchfunctionality can be provided using CoreImage's kernel shading language.

The read-only-memory (ROM) 1330 stores static data and instructions thatare needed by the processing unit(s) 1310 and other modules of theelectronic system. The permanent storage device 1335, on the other hand,is a read-and-write memory device. This device is a non-volatile memoryunit that stores instructions and data even when the electronic system1300 is off. Some embodiments of the invention use a mass-storage device(such as a magnetic or optical disk and its corresponding disk drive,integrated flash memory) as the permanent storage device 1335.

Other embodiments use a removable storage device (such as a floppy disk,flash memory device, etc., and its corresponding drive) as the permanentstorage device. Like the permanent storage device 1335, the systemmemory 1320 is a read-and-write memory device. However, unlike storagedevice 1335, the system memory 1320 is a volatile read-and-write memory,such a random access memory. The system memory 1320 stores some of theinstructions and data that the processor needs at runtime. In someembodiments, the invention's processes are stored in the system memory1320, the permanent storage device 1335, and/or the read-only memory1330. For example, the various memory units include instructions forprocessing multimedia clips in accordance with some embodiments. Fromthese various memory units, the processing unit(s) 1310 retrievesinstructions to execute and data to process in order to execute theprocesses of some embodiments.

The bus 1305 also connects to the input and output devices 1340 and1345. The input devices 1340 enable the user to communicate informationand select commands to the electronic system. The input devices 1340include alphanumeric keyboards and pointing devices (also called “cursorcontrol devices”), cameras (e.g., webcams), microphones or similardevices for receiving voice commands, etc. The output devices 1345display images generated by the electronic system or otherwise outputdata. The output devices 1345 include printers and display devices, suchas cathode ray tubes (CRT) or liquid crystal displays (LCD), as well asspeakers or similar audio output devices. Some embodiments includedevices such as a touchscreen that function as both input and outputdevices.

Finally, as shown in FIG. 13, bus 1305 also couples electronic system1300 to a network 1325 through a network adapter (not shown). In thismanner, the computer can be a part of a network of computers (such as alocal area network (“LAN”), a wide area network (“WAN”), or anIntranet), or a network of networks, such as the Internet. Any or allcomponents of electronic system 1300 may be used in conjunction with theinvention.

Some embodiments include electronic components, such as microprocessors,storage and memory that store computer program instructions in amachine-readable or computer-readable medium (alternatively referred toas computer-readable storage media, machine-readable media, ormachine-readable storage media). Some examples of such computer-readablemedia include RAM, ROM, read-only compact discs (CD-ROM), recordablecompact discs (CD-R), rewritable compact discs (CD-RW), read-onlydigital versatile discs (e.g., DVD-ROM, dual-layer DVD-ROM), a varietyof recordable/rewritable DVDs (e.g., DVD-RAM, DVD-RW, DVD+RW, etc.),flash memory (e.g., SD cards, mini-SD cards, micro-SD cards, etc.),magnetic and/or solid state hard drives, read-only and recordableBlu-Ray® discs, ultra density optical discs, any other optical ormagnetic media, and floppy disks. The computer-readable media may storea computer program that is executable by at least one processing unitand includes sets of instructions for performing various operations.Examples of computer programs or computer code include machine code,such as is produced by a compiler, and files including higher-level codethat are executed by a computer, an electronic component, or amicroprocessor using an interpreter.

While the above discussion primarily refers to microprocessor ormulti-core processors that execute software, some embodiments areperformed by one or more integrated circuits, such as applicationspecific integrated circuits (ASICs) or field programmable gate arrays(FPGAs). In some embodiments, such integrated circuits executeinstructions that are stored on the circuit itself. In addition, someembodiments execute software stored in programmable logic devices(PLDs), ROM, or RAM devices.

As used in this specification and any claims of this application, theterms “computer”, “server”, “processor”, and “memory” all refer toelectronic or other technological devices. These terms exclude people orgroups of people. For the purposes of the specification, the termsdisplay or displaying means displaying on an electronic device. As usedin this specification and any claims of this application, the terms“computer readable medium,” “computer readable media,” and “machinereadable medium” are entirely restricted to tangible, physical objectsthat store information in a form that is readable by a computer. Theseterms exclude any wireless signals, wired download signals, and anyother ephemeral signals.

While the invention has been described with reference to numerousspecific details, one of ordinary skill in the art will recognize thatthe invention can be embodied in other specific forms without departingfrom the spirit of the invention. For instance, a number of the figures(including FIGS. 2, 7, and 10) conceptually illustrate processes. Thespecific operations of these processes may not be performed in the exactorder shown and described. The specific operations may not be performedin one continuous series of operations, and different specificoperations may be performed in different embodiments. Furthermore, theprocess could be implemented using several sub-processes, or as part ofa larger macro process. Thus, one of ordinary skill in the art wouldunderstand that the invention is not to be limited by the foregoingillustrative details, but rather is to be defined by the appendedclaims.

V. Map Service

Various embodiments may operate within a map service operatingenvironment. FIG. 14 illustrates one possible embodiment of an operatingenvironment 1400 for a map service (also referred to as a mappingservice) 1430 and client devices 1402 a-1402 c. In some embodiments,devices 1402 a, 1402 b, and 1402 c communicate over one or more wired orwireless networks 1410. For example, wireless network 1410, such as acellular network, can communicate with a wide area network (WAN) 1420,such as the Internet, by use of gateway 1414. A gateway 1414 in someembodiments provides a packet oriented mobile data service, such asGeneral Packet Radio Service (GPRS), or other mobile data serviceallowing wireless networks to transmit data to other networks, such aswide area network 1420. Likewise, access device 1412 (e.g., IEEE 802.11gwireless access device) provides communication access to WAN 1420.

The client devices 1402 a and 1402 b can be any portable electronic orcomputing device capable of communicating with a map service (e.g.,smart phone, tablet, laptop computer, etc.). Device 1402 c can be anynon-portable electronic or computing device capable of communicatingwith a map service (e.g., desktop computer, etc.). These devices may bemultifunction devices capable of various functions (e.g., placing phonecalls, sending electronic messages, producing documents, etc.). Thoughthe devices 1402 a-1402 c are not shown as each accessing the mapservice 1430 via either the wireless network 1410 and gateway 1414 orthe access device 1412, one of ordinary skill in the art will recognizethat the client devices of some embodiments may access the map servicevia multiple different wired and/or wireless protocols.

Devices 1402 a-1402 c can also establish communications by other means.For example, these devices may communicate with other wireless devices(e.g., other devices 1402 b, cell phones, etc.) over the wirelessnetwork 1410 or through access device 1412. Likewise the devices 1402a-1402 c can establish peer-to-peer communications 1440 (e.g., apersonal area network) by use of one or more communication subsystems,such as Bluetooth® communication or similar peer-to-peer protocols.

Devices 1402 a-1402 c may also receive Global Positioning Satellite(GPS) signals from GPS satellites 1460. In addition, in some embodimentsthe map service 1430 and other services 1450 may also receive GPSsignals from GPS satellites 1460.

A map service 1430 may provide map services for one or more clientdevices 1402 a-1402 c in communication with the map service 1430 throughvarious communication methods and protocols. A map service 1430 in someembodiments provides map information (e.g., map tiles used by the clientdevices to generate a two-dimensional or three-dimensional mappresentation) and other map-related data, such as two-dimensional mapimage data (e.g., aerial view of roads utilizing satellite imagery),three-dimensional map image data (e.g., traversable map withthree-dimensional features, such as buildings), route and directioncalculations (e.g., driving route data, ferry route calculations,directions between two points for a pedestrian, etc.), real-timenavigation data (e.g., turn-by-turn visual navigation data in two orthree dimensions), traffic data, location data (e.g., where the clientdevice currently is located), and other geographic data (e.g., wirelessnetwork coverage, weather, traffic information, or nearbypoints-of-interest). In various embodiments, the map service data mayinclude localized labels for different countries or regions. Localizedlabels may be utilized to present map labels (e.g., street names, citynames, points of interest) in different languages on client devices. Theclient devices 1402 a-1402 c may utilize these map services to obtainthe various map service data, then implement various techniques toprocess the data and provide the processed data to various entities(e.g., internal software or hardware modules, display screens of theclient devices, external display screens, or other external systems ordevices.

The map service 1430 of some embodiments provides map services bygenerating and distributing the various types of map service data listedabove, including map information used by the client device to generateand display a map presentation. In some embodiments, the map informationincludes one or more map tiles. The map tiles may include raster imagedata (e.g., bmp, gif, jpg/jpeg/, png, tiff, etc. data) for display as amap presentation. In some embodiments, the map tiles providevector-based map data, with the map presentation data encoded usingvector graphics (e.g., svg or drw data). The map tiles may also includevarious other information pertaining to the map, such as metadata. Someembodiments also encode style data (e.g., used to generate textures)into the map tiles. The client device processes (e.g., renders) thevector and/or raster image data to generate a map presentation fordisplay as a two-dimensional or three-dimensional map presentation. Totransmit the map tiles to a client device 1402 a-1402 c, the map service1430 of some embodiments, performs various optimization techniques toanalyze a map tile before encoding the tile.

In some embodiments, the map tiles are generated by the map service 1430for different possible display resolutions at the client devices 1402a-1402 c. In some embodiments, the higher zoom levels may include moredetail (e.g., more street level information, etc.). On the other hand,map tiles for lower zoom levels may omit certain data (e.g., the streetlevel details would not be used when displaying the entire earth).

To generate the map information (e.g., map tiles), the map service 1430may obtain map service data from internal or external sources. Forexample, satellite imagery used in map image data may be obtained fromexternal services, or internal systems, storage devices, or nodes. Otherexamples may include, but are not limited to, GPS assistance servers,wireless network coverage databases, business or personal directories,weather data, government information (e.g., construction updates or roadname changes), or traffic reports. Some embodiments of a map service mayupdate map service data (e.g., wireless network coverage) for analyzingfuture requests from client devices.

In some embodiments, the map service 1430 responds to requests from theclient devices 1402 a-1402 c for map information. The client devices mayrequest specific portions of a map, or specific map tiles (e.g.,specific tiles at specific zoom levels). In some embodiments, the clientdevices may provide the map service with starting locations (or currentlocations) and destination locations for a route calculations, andrequest turn-by-turn navigation data. A client device may also requestmap service rendering information, such as map textures or style sheets.Requests for other geographic data may include, but are not limited to,current location, wireless network coverage, weather, trafficinformation, or nearby points-of-interest.

The client devices 1402 a-1402 c that obtain map service data from themap service 1430 and render the data to display the map information intwo-dimensional and/or three-dimensional views. Some embodiments displaya rendered map and allow a user, system, or device to provide input tomanipulate a virtual camera for the map, changing the map displayaccording to the virtual camera's position, orientation, andfield-of-view. Various forms and input devices are implemented tomanipulate a virtual camera. In some embodiments, touch input, throughcertain single or combination gestures (e.g., touch-and-hold or a swipe)manipulate the virtual camera. Other embodiments allow manipulation ofthe device's physical location to manipulate a virtual camera. Otherinput devices to the client device may be used including, e.g., auditoryinput (e.g., spoken words), a physical keyboard, mouse, and/or ajoystick. Some embodiments provide various visual feedback to virtualcamera manipulations, such as displaying an animation of possiblevirtual camera manipulations when transitioning from two-dimensional mapviews to three-dimensional map views.

In some embodiments, a client device 1402 a-1402 c implements anavigation system (e.g., turn-by-turn navigation), which may be part ofan integrated mapping and navigation application. A navigation systemprovides directions or route information, which may be displayed to auser. As mentioned above, a client device may receive both map imagedata and route data from the map service 1430. In some embodiments, thenavigation feature of the client device provides real-time route anddirection information based upon location information and routeinformation received from a map service and/or other location system,such as a Global Positioning Satellite (GPS) system. A client device maydisplay map image data that reflects the current location of the clientdevice and update the map image data in real-time. The navigationfeatures may provide auditory or visual directions to follow a certainroute, and some embodiments display map data from the perspective of avirtual camera biased toward the route destination during turn-by-turnnavigation.

The client devices 1402 a-1402 c of some embodiments implement varioustechniques to utilize the received map service data (e.g., optimizedrendering techniques). In some embodiments, a client device locallystores some of the information used to render map data. For instance,client devices may store style sheets with rendering directions forimage data containing style identifiers, common image textures (in orderto decrease the amount of map image data transferred from the mapservice), etc. The client devices of some embodiments may implementvarious techniques to render two-dimensional and three-dimensional mapimage data, including, e.g., generating three-dimensional buildings outof two-dimensional building footprint data; modeling two-dimensional andthree-dimensional map objects to determine the client devicecommunication environment; generating models to determine whether maplabels are seen from a certain virtual camera position; and generatingmodels to smooth transitions between map image data.

In various embodiments, map service 1430 and/or other service(s) 1450are configured to process search requests from any of the clientdevices. Search requests may include but are not limited to queries forbusinesses, addresses, residential locations, points of interest, orsome combination thereof. Map service 1430 and/or other service(s) 1450may be configured to return results related to a variety of parametersincluding but not limited to a location entered into an address bar orother text entry field (including abbreviations and/or other shorthandnotation), a current map view (e.g., user may be viewing one location onthe multifunction device while residing in another location), currentlocation of the user (e.g., in cases where the current map view did notinclude search results), and the current route (if any). In variousembodiments, these parameters may affect the composition of the searchresults (and/or the ordering of the search results) based on differentpriority weightings. In various embodiments, the search results that arereturned may be a subset of results selected based on specific criteriaincluding but not limited to a quantity of times the search result(e.g., a particular point of interest) has been requested, a measure ofquality associated with the search result (e.g., highest user oreditorial review rating), and/or the volume of reviews for the searchresults (e.g., the number of times the search result has been review orrated).

In various embodiments, map service 1430 and/or other service(s) 1450are configured to provide auto-complete search results that aredisplayed on the client device, such as within the mapping application.For instance, auto-complete search results may populate a portion of thescreen as the user enters one or more search keywords on themultifunction device. In some cases, this feature may save the user timeas the desired search result may be displayed before the user enters thefull search query. In various embodiments, the auto complete searchresults may be search results found by the client on the client device(e.g., bookmarks or contacts), search results found elsewhere (e.g.,from the Internet) by map service 1430 and/or other service(s) 1450,and/or some combination thereof. As is the case with commands, any ofthe search queries may be entered by the user via voice or throughtyping. The multifunction device may be configured to display searchresults graphically within any of the map display described herein. Forinstance, a pin or other graphical indicator may specify locations ofsearch results as points of interest. In various embodiments, responsiveto a user selection of one of these points of interest (e.g., a touchselection, such as a tap), the multifunction device is configured todisplay additional information about the selected point of interestincluding but not limited to ratings, reviews or review snippets, hoursof operation, store status (e.g., open for business, permanently closed,etc.), and/or images of a storefront for the point of interest. Invarious embodiments, any of this information may be displayed on agraphical information card that is displayed in response to the user'sselection of the point of interest.

In various embodiments, map service 1430 and/or other service(s) 1450provide one or more feedback mechanisms to receive feedback from clientdevices 1402 a-1402 c. For instance, client devices may provide feedbackon search results to map service 1430 and/or other service(s) 1450(e.g., feedback specifying ratings, reviews, temporary or permanentbusiness closures, errors etc.); this feedback may be used to updateinformation about points of interest in order to provide more accurateor more up-to-date search results in the future. In some embodiments,map service 1430 and/or other service(s) 1450 may provide testinginformation to the client device (e.g., an A/B test) to determine whichsearch results are best. For instance, at random intervals, the clientdevice may receive and present two search results to a user and allowthe user to indicate the best result. The client device may report thetest results to map service 1430 and/or other service(s) 1450 to improvefuture search results based on the chosen testing technique, such as anA/B test technique in which a baseline control sample is compared to avariety of single-variable test samples in order to improve results.

While the invention has been described with reference to numerousspecific details, one of ordinary skill in the art will recognize thatthe invention can be embodied in other specific forms without departingfrom the spirit of the invention. For instance, many of the figuresillustrate various touch gestures. However, many of the illustratedoperations could be performed via different touch gestures (e.g., aswipe instead of a tap, etc.) or by non-touch input (e.g., using acursor controller, a keyboard, a touchpad/trackpad, a near-touchsensitive screen, etc.). In addition, a number of the figuresconceptually illustrate processes. The specific operations of theseprocesses may not be performed in the exact order shown and described.The specific operations may not be performed in one continuous series ofoperations, and different specific operations may be performed indifferent embodiments. Furthermore, the process could be implementedusing several sub-processes, or as part of a larger macro process. Oneof ordinary skill in the art would understand that the invention is notto be limited by the foregoing illustrative details, but rather is to bedefined by the appended claims.

What is claimed is:
 1. A non-transitory machine readable medium storinga map application executable by at least one processing unit of adevice, the application comprising sets of instructions for: identifyinga transit route between a starting location and a destination, thetransit route comprising a set of transit legs each of which serviced bytransit vehicles, each transit vehicle being associated with one of aplurality of transit lines; categorizing each transit line as one of ahigh frequency transit line and a low frequency transit line bydetermining whether transit vehicles of each transit line depart atleast once during a predetermined period of time; and based on thecategorization, displaying departure schedules of high frequency transitlines in a frequency of departure format while displaying departureschedules of low frequency transit lines in an absolute time format. 2.The non-transitory machine readable medium of claim 1, wherein the setof instructions for categorizing a transit line comprises a set ofinstructions for categorizing the transit line based on a number ofdepartures of transit vehicles of the transit line from a first transitstation of a transit leg that is serviced by the transit line.
 3. Thenon-transitory machine readable medium of claim 2, wherein the firsttransit station of the transit leg comprises a transit station fromwhich the transit leg starts.
 4. The non-transitory machine readablemedium of claim 2, wherein the set of instructions for categorizing thetransit line further comprises a set of instructions for categorizingthe transit line as a high frequency transit line when the transitvehicles of the transit line depart from the first transit station onaverage more than once during a predetermined period of time.
 5. Thenon-transitory machine readable medium of claim 4, wherein the set ofinstructions for displaying the departure schedule of the high frequencytransit line comprises a set of instructions for displaying a timeinterval between each pair of departures of the transit vehicles of thetransit line from the first station.
 6. The non-transitory machinereadable medium of claim 5, wherein the set of instructions fordisplaying the time interval comprises a set of instructions fordisplaying one of an exact time, an approximate time, and a time range.7. The non-transitory machine readable medium of claim 2, wherein theset of instructions for categorizing the transit line further comprisesa set of instructions for categorizing the transit line as a lowfrequency transit line when the transit vehicles of the transit line donot depart from the first transit station on average more than onceduring a predetermined period of time.
 8. The non-transitory machinereadable medium of claim 7, wherein the set of instructions fordisplaying a departure schedule of the low frequency transit linecomprises a set of instructions for displaying a particular time forstarting a transit trip using the transit route.
 9. The non-transitorymachine readable medium of claim 8, wherein the application furthercomprises a set of instructions for tracking a current location of thedevice, wherein the set of instructions for displaying the particulartime comprises a set of instructions for displaying the particular timefor starting the transit trip differently based on the current locationof the device.
 10. The non-transitory machine readable medium of claim9, wherein the set of instructions for displaying the particular timefor starting the transit trip comprises a set of instructions fordisplaying the particular time as a departure time of a next transitvehicle of the transit line when the current location of the device isat or inside a threshold vicinity of the first transit station.
 11. Thenon-transitory machine readable medium of claim 10, wherein the set ofinstructions for displaying the particular time for starting the transittrip comprises a set of instructions for displaying the particular timeas a time to leave the current location of the device when the currentlocation of the device is outside the threshold vicinity of the firsttransit station.
 12. The non-transitory machine readable medium of claim11, wherein the time to leave the current location is calculated basedon a walking distance between the current location of the device and thefirst transit station.
 13. The non-transitory machine readable medium ofclaim 1, wherein the set of instructions for categorizing each transitline comprises sets of instructions for: sending the identified transitroute to a set of servers; and receiving from the server set theidentified transit route with each transit line categorized as one of ahigh frequency transit line and a low frequency transit line.
 14. Thenon-transitory machine readable medium of claim 1, wherein the displayeddeparture schedules include a travel time of the transit route.
 15. Anelectronic device comprising: a set of processing units for executingsets of instructions; and a non-transitory machine readable mediumstoring a map application executable by at least one of the processingunits of the device, the application comprising sets of instructionsfor: identifying a transit route between a starting location and adestination, the transit route comprising a set of transit legs each ofwhich serviced by transit vehicles, each transit vehicle beingassociated with one of a plurality of transit lines; categorizing eachtransit line as one of a high frequency transit line and a low frequencytransit line by determining whether transit vehicles of each transitline depart at least once during a predetermined period of time; andbased on the categorization, displaying departure schedules of highfrequency transit lines in a frequency of departure format whiledisplaying departure schedules of low frequency transit lines in anabsolute time format.
 16. The electronic device of claim 15, wherein theset of instructions for displaying the departure schedules comprises aset of instructions for displaying a departure schedule of a transitline in a navigation banner that comprises navigation instructions for atransit leg that is serviced by the transit line.
 17. The electronicdevice of claim 16, wherein the navigation banner is one of a pluralityof navigation banners that are displayed to a user during a transitnavigation presentation for navigating the transit route.
 18. Theelectronic device of claim 15, wherein the set of instructions fordisplaying the departure schedules comprises a set of instructions fordisplaying a departure schedule of a particular transit line from atransit station in the transit station's placecard that comprisesdeparture schedules of a plurality of transit lines that depart from thetransit station.
 19. The electronic device of claim 18, wherein theparticular transit line comprises a high frequency transit line, whereinthe set of instructions for displaying the departure schedule of theparticular transit line comprises a set of instructions for displayingthe departure schedule as a frequency of departures of transit vehiclesof the particular transit line from the transit stations in theplacecard.
 20. The electronic device of claim 19, wherein the set ofinstructions for displaying the departure schedule of the particulartransit line further comprises a set of instructions for displaying acountdown to an upcoming departure time of the particular transit linein addition to displaying the frequency of departures of the particulartransit line.
 21. The electronic device of claim 15, wherein thedisplayed departure schedules include a travel time of the transitroute.
 22. The electronic device of claim 15, wherein each transit linecomprises one of a bus line, a subway line, a light rail line, and aferry line.